This should be fixed at least in Ubuntu jammy
cat ../CMakeLists.txt
cmake_minimum_required(VERSION 3.22)
project(test)
find_package(pugixml REQUIRED)
add_executable(test test.cpp)
target_link_libraries(test pugixml)
cat ../test.cpp
#include <pugixml.hpp>
#include <stdio.h>
int main()
{
printf("%d\n",PUGIXML_VERSION);
}
$ cmake ..
-- The C compiler identification is GNU 11.2.0
-- The CXX compiler identification is GNU 11.2.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Configuring done
-- Generating done
-- Build files have been written to: /foo/bar
# make VERBOSE=1
/usr/bin/cmake -S/foo -B/foo/bar --check-build-system CMakeFiles/Makefile.cmake 0
/usr/bin/cmake -E cmake_progress_start /foo/bar/CMakeFiles
/foo/bar//CMakeFiles/progress.marks
make -f CMakeFiles/Makefile2 all
make[1]: Entering directory '/foo/bar'
make -f CMakeFiles/test.dir/build.make CMakeFiles/test.dir/depend
make[2]: Entering directory '/foo/bar'
cd /foo/bar && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /foo /foo
/foo/bar /foo/bar /foo/bar/CMakeFiles/test.dir/DependInfo.cmake --color=
make[2]: Leaving directory '/foo/bar'
make -f CMakeFiles/test.dir/build.make CMakeFiles/test.dir/build
make[2]: Entering directory '/foo/bar'
[ 50%] Building CXX object CMakeFiles/test.dir/test.cpp.o
/usr/bin/c++ -MD -MT CMakeFiles/test.dir/test.cpp.o -MF
CMakeFiles/test.dir/test.cpp.o.d -o CMakeFiles/test.dir/test.cpp.o -c
/foo/test.cpp
[100%] Linking CXX executable test
/usr/bin/cmake -E cmake_link_script CMakeFiles/test.dir/link.txt --verbose=1
/usr/bin/c++ CMakeFiles/test.dir/test.cpp.o -o test
/usr/lib/x86_64-linux-gnu/libpugixml.so.1.12
make[2]: Leaving directory '/foo/bar'
[100%] Built target test
make[1]: Leaving directory '/foo/bar'
/usr/bin/cmake -E cmake_progress_start /foo/bar/CMakeFiles 0
# ./test
1120
** Changed in: pugixml (Ubuntu)
Status: Confirmed => Won't Fix
** Changed in: pugixml (Ubuntu)
Status: Won't Fix => Fix Released
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1799660
Title:
CMake config file references files with wrong path
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/pugixml/+bug/1799660/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs