You are not logged in.

#26 2023-12-09 22:16:39

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,410
Website

Re: why do we need packages in pacman? why not download files one by one?

So far the argument appears to be working with packages fails, so lets work with files that have hundreds of times more opportunities to fail in exactly the same way.

And I think you should look at /var/lib/pacman/local.  I don't think working by file would make it any more simple.

Offline

#27 2023-12-10 02:51:47

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,639

Re: why do we need packages in pacman? why not download files one by one?

cypa wrote:
Scimmia wrote:

No, it's not less files on the user filesystem. The potential smaller downloads would come from not redownloading files that haven't changed. A package is the files needed for the program, they will be there no matter what. You would not have less install/update operations, as a program update is a program update.

wait, have you forgot the package archive files itself and temporary files/directories needed to unpack the archives?
is unpacking an additional operation itself?

for example, take the core/linux package with the kernel - are you aware what pacman update scripts do?
- remove vmlinuz and initramfs boot files
- do some processing of update packages (and all the processing time your system is not bootable at all - if power fails then you could not boot OS!)
- then place new files vmlinuz and initramfs

but if you do not need process whole package archives then it's easy to use replace file atomic operation for boot files ... isn't it better?

Yeah, this has nothing to do with the packages vs files, you have the exact same thing either way. The kernel still get installed to /usr then copied to /boot, and the initramfs still needs to be generated for the new kernel. Your 'solution' does nothing for this at all.

Online

#28 2023-12-10 16:39:55

twelveeighty
Member
From: Alberta, Canada
Registered: 2011-09-04
Posts: 1,096

Re: why do we need packages in pacman? why not download files one by one?

While I do not agree with OP's premise, I think I understand its point. It is an extension to the 'precompiled' vs. 'source-only' package philosophy. If package X needs to go from version 1.2-1 to 1.3-1 because line 99 of source file main.c needs to change from 'if cond < 0' to 'if cond <= 0' then OP's point is that the most efficient method of distributing that change is to communicate 'add = at position 10 to line 99 of file main.c` only.

Even if you take the compilation out of the equation it still leaves a massive amount of problems to resolve that package management currently provides by distributing packages in bundles that have been mentioned in this thread.

Offline

#29 2023-12-10 16:57:30

icar
Member
From: Catalunya
Registered: 2020-07-31
Posts: 464

Re: why do we need packages in pacman? why not download files one by one?

Something more sensible to suggest would be
https://github.com/facebook/zstd/wiki/Z … ing-engine. Having mirrors with the patch file would allow you to use it together with the local pacman cache to download diffs of the packages.

Offline

#30 2023-12-10 20:45:57

seth
Member
Registered: 2012-09-03
Posts: 52,266

Re: why do we need packages in pacman? why not download files one by one?

Allan suggested to curb your expectations on delta updates.
But even if they can reduce the data transfer, I still don't know how to square that w/ the OPs explicit argument that

packages are basically archives of files which is useful for dial-up download but now we are always online ...

which seems to point into the exact opposite direction.
*shrug*

Offline

Board footer

Powered by FluxBB