Juan RP
f8d8f91a08
Implement support to "preserve" existent on-disk files.
...
See NEWS for more information. Fix #51
2014-08-01 15:09:51 +02:00
Juan RP
04c7647492
lib/package_unpack.c: fix a typo that made modified files to not be unpacked.
2014-07-30 18:50:43 +02:00
Juan RP
cc6f9901f1
Fix #50 (Existent files on disk might be overwritten by packages with conf_files).
2014-07-30 16:18:57 +02:00
Juan RP
b63cc62e3d
lib/package_unpack.c: add some comments.
2014-07-02 11:30:41 +02:00
Juan RP
18e0524287
libxbps: optimize rootdir access/creation by checking/creating it only once.
2014-05-27 10:02:01 +02:00
Juan RP
8c47021ec3
Fix #31 and add new test case to reproduce it.
2014-02-25 22:55:39 +01:00
Juan RP
5eea259c13
Remove the config.h kludge and override vasprintf detection via HAVE_VASPRINTF.
2014-01-20 18:50:33 +01:00
Juan RP
16fc064aef
Remove obsolete files also on package reinstalls (and downgrades).
2014-01-15 21:52:35 +01:00
Juan RP
6943eedd26
Partial revert of 36adf15
(lib code is not yet ready).
2014-01-15 21:03:53 +01:00
Juan RP
36adf15c6b
tests: new test to verify obsolete files code works in updates and reinstalls.
2014-01-15 20:59:49 +01:00
Juan RP
92a73a9a54
lib/package_unpack.c: remove redundant assertions.
2013-12-25 09:00:51 +01:00
Juan RP
0cf9047bd2
unpack: use files.plist from binpkg when checking for configuration files.
2013-12-25 08:40:45 +01:00
Juan RP
73509b3556
lib/package_unpack.c: remove dead code (softreplace).
2013-12-25 08:35:55 +01:00
Juan RP
3c0edd40c8
lib/package_unpack.c: only create rootdir if it doesn't exist once.
2013-12-21 12:03:38 +01:00
Juan RP
79bf795e1a
lib/package_unpack.c: make clang stfu due to -Wmissing-field-initializers.
2013-11-19 10:39:46 +01:00
Juan RP
8d7c899d48
lib/package_unpack.c: initiliaze struct rather than memset.
2013-11-18 18:23:31 +01:00
Juan RP
44533f9f57
lib/package_unpack.c: compute unpack cb stats only once.
2013-11-15 10:36:31 +01:00
Juan RP
6d9bb47fba
unpack: make sure to remove only on-disk files if file type does not match.
...
Added another ATF test-case to make sure it works properly.
2013-11-09 08:59:02 +01:00
Juan RP
8f36f8e638
Make sure that configuration files are properly kept or unpacked.
...
Added two new test cases to verify it works as advertised.
2013-11-06 10:45:33 +01:00
Juan RP
c1fafcd339
Fix #20 and added an ATF test-case.
2013-11-05 09:56:36 +01:00
Juan RP
747f250202
unpack: apply correctly file permissions to existent files.
...
Will be backported to the 0.26.x branch.
2013-10-30 12:02:16 +01:00
Juan RP
4057e4961c
Use C99 for loop initializers.
...
That means that a C99 compiler is now mandatory.
2013-09-15 10:06:49 +02:00
Juan RP
571d8748b4
lib/package_unpack.c: fix a double free.
2013-08-30 15:34:29 +02:00
Juan RP
24ff0472dd
Use fs blksize from stat(2)ed file when reading archives.
2013-08-29 14:30:14 +02:00
Juan RP
20fb38142b
lib/package_unpack.c: fixed two memleaks.
2013-08-29 12:06:04 +02:00
Juan RP
52fc384e4e
Fixed some issues/warnings found by clang-analyzer.
2013-06-20 11:25:43 +02:00
Juan RP
42c0766c00
Get rid of libfetch and proplib external dependencies.
...
The list of required external deps is now confuse, libarchive and openssl.
libxbps now includes a wrapper for proplib prefixed with xbps_ rather than prop_.
2013-06-20 10:26:12 +02:00
Juan RP
9d80524a34
Minor optimization: no need to check if obj is NULL, prop_object_type() does that already.
2013-06-14 12:22:29 +02:00
Juan RP
db1efb3aa6
Relax memory requirements on 64bit platforms; fix two memleaks.
2013-06-12 10:04:10 +02:00
Juan RP
99be698979
Use a single file to store repository data.
...
This is just the starting point to extend repositories with PGP signatures.
2013-06-10 10:28:39 +02:00
Juan RP
c22dfa8d52
Make sure that pkg meta plist are always created, even in pkgs without files.
2013-05-17 09:17:32 +02:00
Juan RP
769205db0c
Before unpacking pkg files, first create the pkg metafile (temp fix for #7 ).
2013-05-17 08:24:47 +02:00
Juan RP
7da5f6e8f7
lib/package_unpack.c: remove extra arg in xbps_set_cb_state().
2013-05-15 12:45:35 +02:00
Juan RP
6fdb2e322d
lib/package_unpack.c: remove extra parameter in a variadic function.
2013-04-04 10:15:32 +02:00
Juan RP
c753eae9f7
lib/package_unpack.c: fix two possible memleaks.
2013-04-04 09:55:35 +02:00
Juan RP
0a1ea51e4e
lib/package_unpack.c: fix a meamleak in error path.
2013-04-04 09:17:32 +02:00
Juan RP
8d6f3b5029
unpack: use lchown(2) to set proper uid/gid to symlinks.
2013-03-17 17:13:07 +01:00
Juan RP
57bb7baf5e
unpack: use archive_entry_{filetype,uid,gid,mode} rather than stored struct stat.
2013-03-15 13:18:30 +01:00
Juan RP
5efa1de8d5
lib/package_unpack.c: no need to use a var just to check lstat() rval.
2013-03-11 14:06:47 +01:00
Juan RP
e2b303363b
lib/package_unpack.c: fix a memleak.
2013-03-09 11:07:14 +01:00
Juan RP
c504a73f08
Re-use pkgname from unpack to handle config files.
2013-03-08 10:11:16 +01:00
Juan RP
faacbd4a96
lib/package_unpack.c: fix xbps_entry_install_conf_file() args.
2013-03-08 10:07:48 +01:00
Juan RP
bcae7e83aa
lib/package_unpack.c: pass pkgver to xbps_pkg_exec_buffer() not pkgname.
2013-03-07 12:01:07 +01:00
Juan RP
7e2d5344d3
lib/package_unpack.c: pass correct number of args to xbps_set_cb_state().
2013-03-07 11:52:47 +01:00
Juan RP
e36bedb036
Fix regressions in xbps_unpack_binary_pkg().
2013-03-05 06:42:25 +01:00
Juan RP
7c1a0ac3e8
New pkgdb (0.21) and repo index (1.7) format, see NEWS for info.
2013-03-05 04:08:42 +01:00
Juan RP
e525e2c251
Drop posix_fadvise(3) completely before unpacking.
...
Some systems with small memory might fail to make the preallocation,
as seen in the rpi. It doesn't give us too much gain anyway.
2013-02-20 12:59:11 +01:00
Juan RP
d8769c4873
Workaround fix for 'xbps-install -yf xbps <-> xbps-git'.
2013-02-05 12:10:24 +01:00
Juan RP
5c1688944d
xbps-install: make -f preserve conf files; use it twice to overwrite all files.
2013-02-02 11:30:42 +01:00
Juan RP
b75cd05c37
Use posix_fadvise(2) only if it's available.
2012-12-15 10:47:30 +01:00