llvm-13-dev missing zlib1g-dev dependency

Bug #1967559 reported by Marty Pauley
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
llvm-toolchain-13 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

The llvm-13-dev package appears to be missing a declared dependency on zlib1g-dev.

The cmake configuration in /usr/lib/llvm-13/cmake/LLVMConfig.cmake is looking for ZLIB, but failing to find it due to the missing dependency. (Just below that it also looks for and successfully finds libxml2, as the dependency for that has been declared.)

What I expected: using "find_package(LLVM REQUIRED CONFIG)" in CMakeLists.txt to work.

What happened: it failed;

-- Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)
-- Found LibXml2: /usr/lib/x86_64-linux-gnu/libxml2.so (found version "2.9.12")
-- Found LLVM 13.0.0
-- Using LLVMConfig.cmake in: /usr/lib/llvm-13/cmake
-- Configuring done
CMake Error at CMakeLists.txt:20 (add_executable):
  Target "demo" links to target "ZLIB::ZLIB" but the target was not
  found. Perhaps a find_package() call is missing for an IMPORTED target, or
  an ALIAS target is missing?

Fixed the build failure by running: apt-get install zlib1g-dev

$ lsb_release -rd
Description: Ubuntu 21.10
Release: 21.10
$ apt-cache policy llvm-13-dev
llvm-13-dev:
  Installed: 1:13.0.0-2
  Candidate: 1:13.0.0-2
  Version table:
 *** 1:13.0.0-2 500
        500 http://jp.archive.ubuntu.com/ubuntu impish/universe amd64 Packages
        100 /var/lib/dpkg/status

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in llvm-toolchain-13 (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.