You are not logged in.

#1 2015-06-27 21:43:40

jamespharvey20
Member
Registered: 2015-06-09
Posts: 129

Are core repo packages made via makepkg in base-installed environment?

On a really minimal install, If I download the core systemd 221-1 (221-2 was released a few minutes ago) PKGBUILD and other files and run makepkg-, then:

$ ldd pkg/libsystemd/usr/lib/libudev.so
linux-vdso.so.1
libdl.so.2
librt.so.1
libm.so.6
libresolv.so.2
libcap.so.2
libpthread.so.0
libc.so.6
/usr/lib64/ld-linux-x86-64.so.2
libattr.so.1

The above is the same as if I run ldd on /usr/lib/libudev.so installed straight from the core repo, without running makepkg to generate it.

But, if I do the same (running makepkg) after installing X, plasma (kde), and quite a few other things, then:

$ ldd pkg/libsystemd/usr/lib/libudev.so
{includes the above, PLUS}
libdw.so.1 {in elfutils}
libelf.so.1 {in elfutils}
liblzma.so.5 {in xz}
libbz2.so.1.0 {in bzip2}
libz.so.1 {in zlib}

The systemd package lists xz as a dependency.  But, it doesn't list elfutils, bzip2, or zlib as a dependency.  And, elfutils, bzip2, and zlib are not in base, and are not dependencies of anything in base.  (Since base may be assumed to be installed when listing dependencies.)

Just in the context of building systemd, out of the context of makepkg, this makes sense.  A program can optionally work with packages, and have configure handle on a per compilation basis whether those optional packages are there.

But, makepkg creates a .pkg.tar.xz which can be put in a repository, so this creates a possibility an optional package may be seen by configure on the system running makepkg, that is not on the system installing from the repository.



This obviously doesn't happen through the official repos.  Why not?  Are the core repo's made from makepkg in a base-installed environment only?  So the builder's environment doesn't introduce these "phantom" dependencies?

Last edited by jamespharvey20 (2015-06-27 21:44:19)

Offline

#2 2015-06-27 22:00:54

arojas
Developer
From: Spain
Registered: 2011-10-09
Posts: 2,290

Re: Are core repo packages made via makepkg in base-installed environment?

Packages in official repos are generally built in clean chroots, so only packages in base-devel and those in the package's depends and makedepends arrays are installed at build time

Offline

#3 2015-06-27 22:07:16

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,731
Website

Re: Are core repo packages made via makepkg in base-installed environment?

arojas wrote:

Packages in official repos are generally built in clean chroots, so only packages in base-devel and those in the package's depends and makedepends arrays are installed at build time

Well, they are not technically required to be as evident by this recent ML thread.

Offline

#4 2015-06-27 22:08:38

jamespharvey20
Member
Registered: 2015-06-09
Posts: 129

Re: Are core repo packages made via makepkg in base-installed environment?

Makes sense.  Are clean chroots for this done manually, or is there a program or script used to handle it?

EDIT: Now that I see graysky's answer, should this functionality be integrated with makepkg to prevent some from not doing so?

Last edited by jamespharvey20 (2015-06-27 22:09:29)

Offline

#5 2015-06-27 22:12:27

WorMzy
Administrator
From: Scotland
Registered: 2010-06-16
Posts: 13,544
Website

Re: Are core repo packages made via makepkg in base-installed environment?

jamespharvey20 wrote:

is there a program or script used to handle it?

Yes, look into the devtools package.


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#6 2015-06-27 22:13:57

arojas
Developer
From: Spain
Registered: 2011-10-09
Posts: 2,290

Re: Are core repo packages made via makepkg in base-installed environment?

graysky wrote:

Well, they are not technically required to be as evident by this recent ML thread.

And hence the "generally"

jamespharvey20 wrote:

Makes sense.  Are clean chroots for this done manually, or is there a program or script used to handle it?

https://wiki.archlinux.org/index.php/De … ean_Chroot

Offline

Board footer

Powered by FluxBB