Skip to content

Unable to build PDAL from source, Linking CXX executable bin/lasdump #3826

@jsmoreau

Description

@jsmoreau

I'm trying to build PDAL 2.4.2 from source in a docker container.
GDAL 3.4.0 has already been built and is available.
My base docker image is python:3.8-slim-buster.
I followed the build instructions described here: https://pdal.io/development/compilation/unix.html

Here's the cmake -G Ninja output:

cmake: /usr/local/lib/libcurl.so.4: no version information available (required by cmake)
-- The CXX compiler identification is GNU 8.3.0
-- The C compiler identification is GNU 8.3.0
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Found GDAL: /usr/local/lib/libgdal.so (Required is at least version "3.0")
-- Found GeoTIFF: /usr/local/lib/libgeotiff.so
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11")
-- Found LibXml2: /usr/lib/x86_64-linux-gnu/libxml2.so (found version "2.9.4")
-- Found CURL: /usr/local/lib/libcurl.so (found version "7.73.0")
-- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) (Required is at least version "1.1")
OpenSSL NOT found - `export OPENSSL_ROOT_DIR=___`
Google storage IO will not be available
-- Found PythonInterp: /usr/local/bin/python (found version "3.8.13")
-- Could NOT find LIBEXECINFO (missing: LIBEXECINFO_LIBRARY)
-- Could NOT find LIBUNWIND (missing: LIBUNWIND_LIBRARY LIBUNWIND_INCLUDE_DIR)
-- The following features have been enabled:

 * Unit tests, PDAL unit tests

-- The following OPTIONAL packages have been found:

 * ZSTD
   General compression support
 * LibXml2
 * PkgConfig
 * PythonInterp

-- The following REQUIRED packages have been found:

 * GDAL (required version >= 3.0)
   Provides general purpose raster, vector, and reference system support
 * GeoTIFF
 * ZLIB
   Compression support in BPF
 * CURL
 * Threads, The thread library of the system

-- The following features have been disabled:

 * Bash completion, completion for PDAL command line
 * CPD plugin, Coherent Point Drift (CPD) computes rigid or nonrigid transformations between point sets
 * Draco plugin, Read data in the draco format
 * I3S plugin, Read from a I3S server or from a SLPK file
 * Icebridge plugin, read data in the Icebridge format
 * HDF plugin, read data in the HDF format
 * Matlab plugin, write data to a .mat file
 * NITF plugin, read/write LAS data wrapped in NITF
 * OpenSceneGraph plugin, read/write OpenSceneGraph objects
 * PostgreSQL PointCloud plugin, read/write PostgreSQL PointCloud objects
 * RiVLib plugin, read data in the RXP format
 * rdblib plugin, read data in the RDB format
 * MBIO plugin, add features that depend on MBIO
 * FBX plugin, add features that depend on FBX
 * TEASER++ plugin, TEASER++ computes transformations between point sets
 * TileDB plugin, read/write data from TileDB
 * E57 plugin, read/write data to and from e57 format

-- The following OPTIONAL packages have not been found:

 * PostgreSQL
 * OpenSSL (required version >= 1.1)
 * absl
 * Libexecinfo
 * Libunwind

-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/PDAL-2.4.2-src/build

I got the following error:

[234/513] Linking CXX static library lib/libgtest.a
/usr/bin/cmake: /usr/local/lib/libcurl.so.4: no version information available (required by /usr/bin/cmake)
[235/513] Linking CXX static library lib/libgtest_main.a
/usr/bin/cmake: /usr/local/lib/libcurl.so.4: no version information available (required by /usr/bin/cmake)
[353/513] Linking CXX static library lib/libpdal_arbiter.a
/usr/bin/cmake: /usr/local/lib/libcurl.so.4: no version information available (required by /usr/bin/cmake)
[357/513] Linking CXX static library lib/libpdal_kazhdan.a
/usr/bin/cmake: /usr/local/lib/libcurl.so.4: no version information available (required by /usr/bin/cmake)
[377/513] Linking CXX static library lib/libpdal_lazperf.a
/usr/bin/cmake: /usr/local/lib/libcurl.so.4: no version information available (required by /usr/bin/cmake)
[386/513] Creating library symlink lib/libpdal_util.so.14 lib/libpdal_util.so
/usr/bin/cmake: /usr/local/lib/libcurl.so.4: no version information available (required by /usr/bin/cmake)
[389/513] Linking CXX executable bin/lasdump
FAILED: bin/lasdump
: && /usr/bin/c++     tools/lasdump/CMakeFiles/lasdump.dir/Dumper.cpp.o tools/lasdump/CMakeFiles/lasdump.dir/Header.cpp.o  -o bin/lasdump  -Wl,-rpath,/tmp/PDAL-2.4.2-src/build/lib lib/libpdal_util.so.14.2.0 lib/libpdal_lazperf.a && :
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::path::parent_path() const'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::directory_iterator::operator*() const'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::remove(std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `typeinfo for std::filesystem::__cxx11::filesystem_error'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::path::has_root_directory() const'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::file_size(std::filesystem::__cxx11::path const&, std::error_code&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::current_path[abi:cxx11]()'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::status(std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::create_directories(std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::remove_all(std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::directory_iterator::operator++()'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::rename(std::filesystem::__cxx11::path const&, std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::create_directory(std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::directory_iterator::directory_iterator(std::filesystem::__cxx11::path const&, std::filesystem::directory_options, std::error_code*)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::absolute(std::filesystem::__cxx11::path const&)'
/usr/bin/ld: lib/libpdal_util.so.14.2.0: undefined reference to `std::filesystem::__cxx11::path::has_filename() const'
collect2: error: ld returned 1 exit status
[391/513] Linking CXX shared library lib/libpdal_base.so.14.2.0
ninja: build stopped: subcommand failed.

Any tips would be welcome!
Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions