Commit Graph

14 Commits

Author SHA1 Message Date
Juan RP 4c70b24941 remove.c: check that required objs are in files.plist.
--HG--
extra : convert_revision : a4e15ac3f48bf496d8671997b8e875c750b42730
2009-03-02 02:47:12 +01:00
Juan RP be170f0cb7 Fix some problems with dangling links while removing a binpkg.
First remove all links, next files and last dirs.
Only check the SHA256 hash for files, skip links and dirs.

--HG--
extra : convert_revision : b1762d5e795959591c732f625d25adfd1840f592
2009-02-28 17:32:38 +01:00
Juan RP 750f467fe6 Take into account $conf_files and $keep_dirs when removing a pkg.
* If a dir is listed in $keep_dirs it won't be removed (anyway any
  directory that is not empty won't either).
* If a config file hasn't been modified (SHA256 hash matches) the
  file will be removed, otherwise it won't be removed.

There's still missing support to handle new configuration files when
there's an existing file, but will do later.

--HG--
extra : convert_revision : 448af95876fc7a47da07a9a910d6111047f72271
2009-02-27 17:41:31 +01:00
Juan RP d9cc1d6b8f Implement support to update required_by objs when removing a pkg.
--HG--
extra : convert_revision : 405986d806ff23ce6348b22a2d7c48e0820ab1b9
2009-02-27 16:03:25 +01:00
Juan RP a00ae944b5 Rename prepost-{inst,rm} to just INSTALL/REMOVE.
Some other changes related for this:
 - Modify binpkg.sh to always insert the INSTALL script at head of
   the archive, and appending files after it.
 - Modify binpkg.sh to compress binpkgs with bzip2 -9 to save some bytes.

--HG--
extra : convert_revision : b651b944f11c48dede1bbcea658182bf0984e8f3
2009-02-26 18:01:18 +01:00
Juan RP 255c48b198 Added support to check SHA256 integrity for binary pkgs.
This currently checks:
 - While removing, any file is checked and if hash doesn't match the
   file is ignored and not removed.
 - While installing, if a binary pkg file doesn't match with the one
   reported by the repository's pkg index file, the process will be
   stopped.

--HG--
extra : convert_revision : 42bb64e89a092f0ff3e7d951e5b26e45d63a60fe
2009-02-26 05:41:49 +01:00
Juan RP fb998feacf xbps-bin: add -v flag, used when installing/removing currently.
--HG--
extra : convert_revision : d543b52213bf3d35b17ef29ff74a879bc4342cef
2009-02-17 00:08:03 +01:00
Juan RP 3a52668aed Reorganize headers and move two funcs into util.c, where they belong.
--HG--
extra : convert_revision : 63d54dddfeb732da2204244fd9f00cff434e5540
2009-02-05 16:53:49 +01:00
Juan RP 7e677c32d9 remove: also remove package metadata stuff.
--HG--
extra : convert_revision : 0a286d1fb33b81a90b0bfb5b41f25c1874d72093
2009-02-03 22:37:20 +01:00
Juan RP 6c252d43d4 Split installation/removal parts in prepost-action scripts.
There are two scripts that can be used now:
	- prepost-inst: for pre/post actions at installation.
	- prepost-rm: for pre/post actions at removal.

--HG--
extra : convert_revision : 5e054758f549f5c81693b825795fbb36e2d5513a
2009-02-03 17:32:51 +01:00
Juan RP 388dd30b45 check_installed_pkgname: returns a bool, so EINVAL is wrong.
--HG--
extra : convert_revision : 6f3d615a27a1bf76962b6daf88929efa8d5cde8e
2009-02-03 17:02:19 +01:00
Juan RP fe8ea8c21c Check that pkg is installed before removing.
--HG--
extra : convert_revision : 4ea85e367ecbc0d39dcba1c8ee63392f0e1177f7
2009-02-03 16:51:42 +01:00
Juan RP edfeec4622 Added support to run pre/post remove actions with binpkgs.
--HG--
extra : convert_revision : ecc70358e9009a0b2f71aaccc5b8b1282417e3bf
2009-02-03 16:07:08 +01:00
Juan RP 4a9125364a xbps-bin: added WIP remove target.
--HG--
extra : convert_revision : 71314f7183384094223cf10bf16ff704ca084883
2009-02-03 03:18:00 +01:00