dependencies shall be changed to adapt for the new libjpeg-turbo [1], which provides the required libjpeg.so.
[1] https://archlinux.org/packages/extra/x86_64/libjpeg-turbo/
| Git Clone URL: | https://aur.archlinux.org/colmap-git.git (read-only, click to copy) |
|---|---|
| Package Base: | colmap-git |
| Description: | General-purpose Structure-from-Motion (SfM) and Multi-View Stereo (MVS) pipeline with a graphical and command-line interface. |
| Upstream URL: | https://colmap.github.io/ |
| Keywords: | 3d multi-view-stereo reconstruction structure-from-motion |
| Licenses: | GPL |
| Conflicts: | colmap |
| Provides: | colmap |
| Submitter: | bartus |
| Maintainer: | bartus (mgrewe) |
| Last Packager: | bartus |
| Votes: | 5 |
| Popularity: | 0.000000 |
| First Submitted: | 2017-03-21 10:48 (UTC) |
| Last Updated: | 2026-04-15 14:20 (UTC) |
dependencies shall be changed to adapt for the new libjpeg-turbo [1], which provides the required libjpeg.so.
[1] https://archlinux.org/packages/extra/x86_64/libjpeg-turbo/
This works okay with cuda 12 btw I use the following somewhat hacky and modified scipt to get the build working. Maybe I should just do cuda < 13.
#!/bin/hint/bash
# Maintainer : bartus <arch-user-repoᘓbartus.33mail.com>
-check_option "debug" "y" && BUILD_TYPE=Debug || BUID_TYPE=Release
-
## Configuration env vars:
_BUILD_CUDA="${BUILD_CUDA:-ON}"
_CUDA_ARCHITECTURES="${CUDA_ARCH:-native}"
@@ -13,7 +11,7 @@
_name=colmap
#fragment="#commit=5bea89263bf5f3ed623b8e6e6a5f022a0ed9c1de"
pkgname=${_name}-git
-pkgver=3.8.r219.g6eb27c01
+pkgver=3.8.r224.gc0d89268
pkgrel=1
pkgdesc="General-purpose Structure-from-Motion (SfM) and Multi-View Stereo (MVS) pipeline with a graphical and command-line interface."
arch=('i686' 'x86_64')
@@ -25,7 +23,7 @@
depends=('cgal' 'ceres-solver' 'gflags' 'metis' 'suitesparse' 'freeglut' 'glew' 'google-glog' 'freeimage' 'libjpeg' 'boost-libs' 'qt5-base' 'flann')
makedepends=('boost' 'cmake' 'eigen' 'git' 'ninja' 'python-sphinx' )
if [ "$_BUILD_CUDA" == "ON" ] ; then
- makedepends+=('cuda<12')
+ makedepends+=('cuda>=12')
optdepends+=('libcudart.so: required for dense reconstruction')
fi
source=("${pkgname}::git+https://github.com/colmap/colmap.git${_fragment}"
@@ -42,9 +40,6 @@
git -C "$pkgname" describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}
-prepare() {
-: # git -C "$pkgname" apply -v "$srcdir"/*.patch
-}
build() {
# determine whether we can precompile CUDA kernels
@@ -62,7 +57,7 @@
fi
_CMAKE_FLAGS+=( -DTESTS_ENABLED=OFF
- -DCMAKE_BUILD_TYPE=${BUILD_TYPE}
+ -DCMAKE_BUILD_TYPE=Release
-DCMAKE_INSTALL_PREFIX=/usr )
cmake "${_CMAKE_FLAGS[@]}" -G Ninja -S "$pkgname" -B build
# shellcheck disable=SC2046 # allow MAKEFLAGS to carry multiple flags.
@@ -83,4 +78,4 @@
install -m644 "${vocab_tree}" "${pkgdir}/usr/share/${_name}/${vocab_tree##*/}"
done
}
Hello @bartus,
The package fails to apply the patch cuda11_gcc11.patch. It compiles though after removing the patch from PKGBUILD.
==> Starting prepare()...
Checking patch src/colmap/CMakeLists.txt...
warning: src/colmap/CMakeLists.txt has type 100644, expected 100755
error: while searching for:
IS_GNU AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 6)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
else()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14")
endif()
endif()
error: patch failed: src/colmap/CMakeLists.txt:43
error: src/colmap/CMakeLists.txt: patch does not apply
==> ERROR: A failure occurred in prepare().
Aborting...
-> error making: colmap-git-exit status 4
-> Failed to install the following packages. Manual intervention is required:
colmap-git - exit status 4
@hrehfeld This is because of the Auto at the start of the pkgbuild:
_CUDA_ARCH="${CUDA_ARCH:-Auto}"
I changed it to:
_CUDA_ARCH="${CUDA_ARCH:-native}"
Or here's documentation on the possible values: https://cmake.org/cmake/help/latest/prop_tgt/CUDA_ARCHITECTURES.html#prop_tgt:CUDA_ARCHITECTURES
Build is currently broken:
-- Targetting Ninja
-- Using /usr/bin/c++ compiler.
-- Found GMP: /usr/lib/libgmp.so
-- Found MPFR: /usr/lib/libmpfr.so
-- Found Boost: /usr/lib64/cmake/Boost-1.80.0/BoostConfig.cmake (found suitable version "1.80.0", minimum required is "1.48")
-- Boost include dirs: /usr/include
-- Boost libraries:
-- Using gcc version 4 or later. Adding -frounding-math
-- Found Qt
-- Module : /usr/lib64/cmake/Qt5Core
-- Module : /usr/lib64/cmake/Qt5OpenGL
-- Module : /usr/lib64/cmake/Qt5Widgets
-- Found CGAL
-- Includes : /usr/include
-- Libraries : CGAL
-- Build type specified as Release
-- Enabling SIMD support
-- Enabling OpenMP support
-- Disabling interprocedural optimization
CMake Error at /usr/share/cmake/Modules/CMakeDetermineCUDACompiler.cmake:279 (message):
CMAKE_CUDA_ARCHITECTURES:
Auto
is not one of the following:
* a semicolon-separated list of integers, each optionally
followed by '-real' or '-virtual'
* a special value: all, all-major, native
Call Stack (most recent call first):
CMakeLists.txt:222 (enable_language)
-- Configuring incomplete, errors occurred!
No possible install without cuda package. I use software solver, I disable BUILD_CUDA but dependencies CUDA (1.3GB) is always installed.
issues and patches at GitHub.BUILD_CUDA=ON|OFF to skip cuda kernel build (default 'ON')CUDA_ARCH="5.2,7.2" to build for a specific Cuda arch, supports multiple values. CMAKE_FLAGS="xxx:yyy" to add extra CMake switches (colon-separated list)export BUILD_CUDA=OFF before buildBUILD_CUDA=OFF ~your-aur-helper~makepkg BUILD_CUDA=OFFyay -S colmap-git --mflags "BUILD_CUDA=OFF"@herbert: Nope, support for Nvidia Fermi architecture (sm≤3.0) was dropped in cuda 9 compiler. You need to downgrade cuda to V8 for compilation to succeed.
btw. driver's capabilities still includes sm_20
Pinned Comments
bartus commented on 2019-04-10 11:42 (UTC) (edited on 2026-04-29 21:18 (UTC) by bartus)
This package is also hosted on GitHub.
issuesandpatchesat GitHub.Use env vars to control build process:
BUILD_CUDA=ON|OFFto skip cuda kernel build (default 'ON')CUDA_ARCH="5.2,7.2"to build for a specific Cuda arch, supports multiple values.CMAKE_FLAGS="xxx:yyy"to add extra CMake switches (colon-separated list)Usage cases:
export BUILD_CUDA=OFFbefore buildBUILD_CUDA=OFF ~your-aur-helper~makepkg BUILD_CUDA=OFFyay -S colmap-git --mflags "BUILD_CUDA=OFF"