apt build-dep exim4-daemon-heavy omits libnsl-dev

Bug #2084391 reported by hanshenrik
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
exim4 (Ubuntu)
Fix Released
Undecided
Unassigned
Noble
Fix Released
Undecided
Lena Voytek

Bug Description

[Impact]

When building exim4-daemon-heavy, libnsl-dev is not explicitly included as a build dependency, which can lead to the following error:
/usr/bin/ld: cannot find -lnsl

The fix should be backported to allow exim4-daemon-heavy to build properly using its libnsl dependency.

This is fixed by adding libnsl-dev as a build dependency.

[Test Plan]

The fix can be confirmed through the reporters provided steps on a noble system after including noble apt source packages:

$ sudo apt purge libnsl-dev
$ sudo apt install dpkg-dev
$ sudo apt build-dep exim4-daemon-heavy
$ apt-get source exim4-daemon-heavy
$ cd exim4-...
$ dpkg-buildpackage -b -uc

[Where problems could occur]

With the inclusion of a new build dependency, builds for other binary packages in exim4 may change. This could lead to ftbfs or other issues from libnsl at buildtime.

[Other Info]

This was fixed in Debian in 4.97-6 and included in Oracular

[Original Description]

"apt build-dep exim4-daemon-heavy" is supposed to install all packages needed for building exim4-daemon-heavy, but it omits libnsl-dev, resulting in
/usr/bin/ld: cannot find -lnsl

steps to reproduce:
sudo apt purge libnsl-dev;
sudo apt install dpkg-dev;
sudo apt build-dep exim4-daemon-heavy;
sudo apt-get source exim4-daemon-heavy;
FOLDER_NAME=$(find /tmp/exim4_builddir -maxdepth 1 -type d -name "exim4-*" | head -n 1);
cd "$FOLDER_NAME";
dpkg-buildpackage -b -uc -us --jobs=$(nproc);

results in the "cannot find -lnsl" error.
---
ProblemType: Bug
ApportVersion: 2.28.1-0ubuntu3.1
Architecture: amd64
CasperMD5CheckResult: unknown
DistroRelease: Ubuntu 24.04
Package: exim4 4.97-4ubuntu4.1
PackageArchitecture: all
ProcEnviron:
 LANG=C
 PATH=(custom, no user)
 SHELL=/bin/bash
 TERM=xterm-256color
 XDG_RUNTIME_DIR=<set>
ProcVersionSignature:

Tags: noble
Uname: Linux 6.8.12-1-pve x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: N/A
_MarkForUpload: True

Related branches

Revision history for this message
hanshenrik (hanshenrik) wrote : Dependencies.txt

apport information

tags: added: apport-collected noble
description: updated
Revision history for this message
hanshenrik (hanshenrik) wrote : NonfreeKernelModules.txt

apport information

Revision history for this message
hanshenrik (hanshenrik) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
Lena Voytek (lvoytek) wrote :

Thank you for the bug report! Looks like libnsl-dev is missing as a build dependency in noble. It is fixed in oracular though. The fix was added through Debian in 4.97-6. I will target the bug to 24.04

Changed in exim4 (Ubuntu Noble):
status: New → Triaged
Changed in exim4 (Ubuntu):
status: New → Fix Released
Lena Voytek (lvoytek)
Changed in exim4 (Ubuntu Noble):
assignee: nobody → Lena Voytek (lvoytek)
status: Triaged → In Progress
Lena Voytek (lvoytek)
description: updated
Revision history for this message
Timo Aaltonen (tjaalton) wrote : Please test proposed package

Hello hanshenrik, or anyone else affected,

Accepted exim4 into noble-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/exim4/4.97-4ubuntu4.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-noble to verification-done-noble. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-noble. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in exim4 (Ubuntu Noble):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-noble
Revision history for this message
Lena Voytek (lvoytek) wrote :

Verified for noble:

# lxc launch ubuntu:noble test-exim4-dependency
# lxc exec test-exim4-dependency bash

# apt update
# apt upgrade -y
# apt purge libnsl-dev
# apt install dpkg-dev

cat <<EOF >/etc/apt/sources.list.d/ubuntu-$(lsb_release -cs)-proposed.list
# Enable Ubuntu proposed archive
deb http://archive.ubuntu.com/ubuntu/ $(lsb_release -cs)-proposed restricted main multiverse universe
EOF

Add src packages - such as

Types: deb-src
URIs: http://us.archive.ubuntu.com/ubuntu/
Suites: noble noble-updates noble-backports noble-proposed
Components: main restricted universe multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

to /etc/apt/sources.list.d/ubuntu.sources

# apt update

# apt build-dep exim4-daemon-heavy

# su ubuntu # download source as a non-root user
# apt-get source exim4-daemon-heavy
# cd exim4-4.97
# dpkg-buildpackage -b -uc
Builds successfully with no dependency issues

tags: added: verification-done verification-done-noble
removed: verification-needed verification-needed-noble
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package exim4 - 4.97-4ubuntu4.2

---------------
exim4 (4.97-4ubuntu4.2) noble; urgency=medium

  * d/p/lp2077893-*.patch: Fix crashes due to memory allocation when using
    PCRE2 (LP: #2077893).
  * d/control: Add libnsl-dev dependency for exim4-daemon-heavy (LP: #2084391).

 -- Lena Voytek <email address hidden> Wed, 16 Oct 2024 15:31:42 -0700

Changed in exim4 (Ubuntu Noble):
status: Fix Committed → Fix Released
Revision history for this message
Andreas Hasenack (ahasenack) wrote : Update Released

The verification of the Stable Release Update for exim4 has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

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.