[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: using build artifacts with autopkgtest



On Tue, Nov 25, 2025 at 12:55:01AM +0100, Lorenzo wrote:

> Is there a way to access the uncleaned build tree from autopkgtest?

Yes, you can use this in debian/tests/control:

Restrictions: build-needed

and the package will be built before running the autopkgtests.

In such case, however, you have to be careful and make sure that you
are testing the installed programs, not the just-built programs.

In some cases, symlinking the built programs to their counterparts
in /usr/bin works well enough.

> when I do so, the test fails because it uses two tiny C build
> artifacts (~40KiB) that are build only to be used in the testsuite and
> are not part of the deb package.

Beware: the "build-needed" keyword above builds the program with the nocheck
build profile. What you could do here is to make sure those tiny build
artifacts are always built, even when using the nocheck build profile.

Hope this helps.


Reply to: