Skip to content

Instantly share code, notes, and snippets.

@ihnorton
Last active July 26, 2022 18:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ihnorton/535164a8206ce3f8e92a1f2598769ecf to your computer and use it in GitHub Desktop.
Save ihnorton/535164a8206ce3f8e92a1f2598769ecf to your computer and use it in GitHub Desktop.

Reproduction for: https://gitlab.kitware.com/cmake/cmake/-/issues/23328

To reproduce:

docker build .

Which should give:

#10 0.549 -- Detecting CXX compile features - done
#10 0.551 terminate called after throwing an instance of 'std::out_of_range'
#10 0.551   what():  basic_string::erase: __pos (which is 1545) > this->size() (which is 18)
#10 0.552 /bin/sh: line 1:    10 Aborted                 $HOME/CMake/build/bin/cmake ../
------
executor failed running [/bin/sh -c mv repro.cmake CMakeLists.txt && ls && mkdir test-build && cd test-build &&     $HOME/CMake/build/bin/cmake ../]: exit code: 134
FROM quay.io/pypa/manylinux2014_aarch64:2022-07-25-160c2d8
WORKDIR /root
ADD repro.cmake repro.cmake
RUN yum update && yum install -y openssl-devel
# currently at `5fc4e121a18d9e403f1541348c2889e9bc153791`
RUN git clone --depth=1 https://github.com/Kitware/CMake && \
mkdir -p CMake/build && \
cd CMake/build && \
cmake .. && \
make -j4
RUN mv repro.cmake CMakeLists.txt && ls && mkdir test-build && cd test-build && \
$HOME/CMake/build/bin/cmake ../
cmake_minimum_required(VERSION 3.22)
project(test)
cmake_path(SET foo "/path/to/something")
cmake_path(REMOVE_FILENAME foo)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment