oneDPL
oneDPL copied to clipboard
Packaging builds break due to writing to protected path
https://github.com/oneapi-src/oneDPL/blob/8ab1b63e6c5ed9b91534f1969d561a6b15f619d8/CMakeLists.txt#L409
When attempting to package this for Clear Linux, this results in trying to write into a protected path:
+ /usr/bin/make DESTDIR=/builddir/build/BUILDROOT/oneDPL-2022.3.0.rc1-1.x86_64 INSTALLROOT=/builddir/build/BUILDROOT/oneDPL-2022.3.0.rc1-1.x86_64 install_prefix=/builddir/build/BUILDROOT/oneDPL-2022.3.0.rc1-1.x86_64 BUILDROOT=/builddir/build/BUILDROOT/oneDPL-2022.3.0.rc1-1.x86_64 BUILD_ROOT=/builddir/build/BUILDROOT/oneDPL-2022.3.0.rc1-1.x86_64 INSTALL_ROOT=/builddir/build/BUILDROOT/oneDPL-2022.3.0.rc1-1.x86_64 install
Install the project...
-- Install configuration: "RelWithDebInfo"
CMake Error: Could not open file for write in copy operation /usr/lib64/cmake/oneDPL/oneDPLConfig.cmake.tmp
CMake Error: : System Error: Inappropriate ioctl for device
CMake Error at /builddir/build/BUILD/oneDPL-oneDPL-2022.3.0-rc1/cmake/scripts/generate_config.cmake:44 (configure_file):
configure_file Problem configuring file
Call Stack (most recent call first):
cmake_install.cmake:54 (include)
make: *** [Makefile:110: install] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.4xDIcf (%install)
Child return code was: 1
...because it bypasses the use of DESTDIR in the make install command to specify a staging directory. This will break for any packaging environment that uses a protected filesystem to create clean package builds.