Skip to content

Commit

Permalink
Include LDPK v2.8 archive to speed up build times.
Browse files Browse the repository at this point in the history
This is a cached version of LDPK, from the following URL:
https://www.3dequalizer.com/user_daten/sections/tech_docs/archives/ldpk-2.8.tgz

The file is included inside mmSolver as convenience to developers and
the file hosters, at the cost of slowing down the Git fetch times for the
mayaMatchMoveSolver repository.

Please note that the provided archive is edited from the original to
just contain the source code needed - no tests, documentation,
images or pre-compiled binaries are included.
  • Loading branch information
david-cattermole committed Oct 23, 2022
1 parent 0a83425 commit 900a8c3
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 0 deletions.
18 changes: 18 additions & 0 deletions external/archives/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,28 @@ This directory is used to store tar/zip files for external
dependencies. The external build scripts use this directory as needed
and sometimes expect files to be added to this directory.

## Autodesk Maya

The following archives may be expected during building and should be
downloaded from [Autodesk](https://www.autodesk.com/):

- Autodesk_Maya_2018_EN_Linux_64bit.tgz
- Autodesk_Maya_2019_Linux_64bit.tgz
- Autodesk_Maya_2020_ML_Linux_64bit.tgz
- Autodesk_Maya_2022_ML_Linux_64bit.tgz
- Autodesk_Maya_2023_ML_Linux_64bit.tgz

## LDPK

A copy of the Lens Distortion Plugin Kit (LDPK) is kept in this
directory, to be used to compile the LDPK library for this project.

The provided archive has been edited from the original to include only
the required source code for the library - all test, documentation and
pre-compiled libraries are removed from the original archive.

- ldpk-2.8.zip

You can get the original copy of the LDPK from the 3DEqualizer website:
https://www.3dequalizer.com/?site=tech_docs&id=110216_01
https://www.3dequalizer.com/user_daten/sections/tech_docs/archives/ldpk-2.8.tgz
Binary file added external/archives/ldpk-2.8.tar
Binary file not shown.
5 changes: 5 additions & 0 deletions scripts/internal/build_mmSolver_linux.bash
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@ MMSCENEGRAPH_CMAKE_CONFIG_DIR="${MMSCENEGRAPH_INSTALL_DIR}/lib/cmake/mmscenegrap
# We don't want to find system packages.
CMAKE_IGNORE_PATH="/lib;/lib64;/usr;/usr/lib;/usr/lib64;/usr/local;/usr/local/lib;/usr/local/lib64;"

# A local copy of LDPK to reduce the amount of downloads to the
# 3DEqualizer website (LDPK doesn't have a git repo to clone from).
LDPK_URL="${PROJECT_ROOT}/external/archives/ldpk-2.8.tar"

# Build mmSolver project
cd ${BUILD_DIR_BASE}
BUILD_DIR_NAME="cmake_linux_maya${MAYA_VERSION}_${BUILD_TYPE}"
Expand Down Expand Up @@ -120,6 +124,7 @@ ${CMAKE_EXE} \
-DMMSOLVER_BUILD_TESTS=${MMSOLVER_BUILD_TESTS} \
-DMAYA_LOCATION=${MAYA_LOCATION} \
-DMAYA_VERSION=${MAYA_VERSION} \
-Dldpk_URL=${LDPK_URL} \
-Dmmscenegraph_DIR=${MMSCENEGRAPH_CMAKE_CONFIG_DIR} \
${PROJECT_ROOT}

Expand Down
8 changes: 8 additions & 0 deletions scripts/internal/build_mmSolver_windows64.bat
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,13 @@ IF EXIST "C:\MinGW" (
SET IGNORE_INCLUDE_DIRECTORIES="C:\MinGW\bin;C:\MinGW\include"
)

:: A local copy of LDPK to reduce the amount of downloads to the
:: 3DEqualizer website (LDPK doesn't have a git repo to clone from).
SET LDPK_URL="%PROJECT_ROOT%\external\archives\ldpk-2.8.tar"
:: Convert back-slashes to forward-slashes.
:: https://stackoverflow.com/questions/23542453/change-backslash-to-forward-slash-in-windows-batch-file
SET "LDPK_URL=%LDPK_URL:\=/%"

:: Optionally use "NMake Makefiles" as the build system generator.
SET CMAKE_GENERATOR=Ninja

Expand Down Expand Up @@ -128,6 +135,7 @@ CHDIR "%BUILD_DIR%"
-DMMSOLVER_BUILD_TESTS=%MMSOLVER_BUILD_TESTS% ^
-DMAYA_LOCATION=%MAYA_LOCATION% ^
-DMAYA_VERSION=%MAYA_VERSION% ^
-Dldpk_URL=%LDPK_URL% ^
-Dmmscenegraph_DIR=%MMSCENEGRAPH_CMAKE_CONFIG_DIR% ^
%PROJECT_ROOT%
if errorlevel 1 goto failed_to_generate
Expand Down

0 comments on commit 900a8c3

Please sign in to comment.