[arch-general] Why are install functions not in PKGBUILD?
It seems like the install functions pre/post_install/upgrade/remove could be defined right in the PKGBUILD. Any particular reason why this isn't or cannot be so?
On Thu, Jun 16, 2011 at 16:27, Matthew Monaco <dgbaley27@verizon.net> wrote:
It seems like the install functions pre/post_install/upgrade/remove could be defined right in the PKGBUILD. Any particular reason why this isn't or cannot be so?
This has come up on the ML before. It's because the PKGBUILD file is not installed to the system, and the system shouldn't have to know or care about the build process, only the install and usage.
But a lot of the stuff in the PKGBUILD is copied into the package database, so why is the install stuff an exception? I don't think it'd be the only multi-line field. On 06/16/2011 04:29 PM, Daenyth Blank wrote:
On Thu, Jun 16, 2011 at 16:27, Matthew Monaco<dgbaley27@verizon.net> wrote:
It seems like the install functions pre/post_install/upgrade/remove could be defined right in the PKGBUILD. Any particular reason why this isn't or cannot be so?
This has come up on the ML before. It's because the PKGBUILD file is not installed to the system, and the system shouldn't have to know or care about the build process, only the install and usage.
On Thu, Jun 16, 2011 at 10:38 PM, Matthew Monaco <dgbaley27@verizon.net> wrote:
But a lot of the stuff in the PKGBUILD is copied into the package database, so why is the install stuff an exception? I don't think it'd be the only multi-line field.
Because the install stuff isn't a multi-line field (of which there are none), it's a bash script defining functions.
Am Thu, 16 Jun 2011 23:21:15 +0200 schrieb Jan Steffens <jan.steffens@gmail.com>:
Because the install stuff isn't a multi-line field (of which there are none), it's a bash script defining functions.
The install scripts are meant for stuff which needs to be done after the package installation directly on the system like updating an icon cache, font cache etc., while the PKGBUILD is a bash script which is used for having packages built from the sources by makepkg and installing them in a fake root like compiling, building the binary package etc. So pacman doesn't see the PKGBUILD, but it sees the install file in the binary package and can only execute the install script functions but not the PKGBUILD functions. And pacman doesn't need to and shouldn't see the build and package functions. Heiko
participants (4)
-
Daenyth Blank
-
Heiko Baums
-
Jan Steffens
-
Matthew Monaco