summaryrefslogtreecommitdiffstats
path: root/src/archive.c
Commit message (Collapse)AuthorAgeFilesLines
* archive: honor username/groupname instead of uid/gidTimo Teräs2010-06-121-1/+4
| | | | Take the uid/gid from passwd and group.
* various: use O_CLOEXEC and add some error checkingTimo Teräs2010-06-111-1/+1
|
* First steps for libapkNatanael Copa2010-06-111-0/+1
|
* apk: remove the unneeded --never-overwriteTimo Teras2009-12-211-18/+1
| | | | | turns out the logic does not work with overlays as expected due to busybox symlinks being unmanaged. remove the useless option.
* archive: overwrite protection needs to use real filenameTimo Teras2009-11-061-1/+7
| | | | | otherwise we always extract the file as .apk-new and the database side just overwrites.
* apk: add --never-overwrite flag (ref #197)Timo Teras2009-11-061-2/+20
| | | | | | | to never ever overwrite a while in the filesystem the user knows about. it gives the impression of extraction succeeding even though nothing was done. this is inteded to be used only for bootstrapping with overlay.
* index, version: support for repository descriptions (fixes #141)Timo Teras2009-09-031-1/+2
| | | | | ability embed description information to repository indexes (e.g. repository name and version) and show it via "apk version -I".
* archive: update for new place of checksum in tar headerTimo Teras2009-08-111-9/+26
| | | | and take checksums for symlinks too.
* db, audit: audit symlinks (by hash of the link target)Timo Teras2009-08-111-1/+1
|
* archive: compile fixNatanael Copa2009-08-031-0/+1
| | | | We need the define for uint16
* apk: use *at instead of chdir+normal file syscallTimo Teras2009-07-311-26/+29
| | | | | | | | this way we never change cwd, and relative filenames are always parsed consistently. this also helps filename construction in many places. this patch also changes '--root' to override location of all configuration to be in the new root. previously it depended on the file which one was used.
* io: fix mmap writing to actually workTimo Teras2009-07-301-1/+1
| | | | | | | apparently it needs to have both PROT_READ and PROT_WRITE. and it needs to be MAP_SHARED for the writing to be effective. oh, and the data needs to be preallocated with ftruncate; otherwise, one gets SIGBUS.
* tar: make checksumming of inner files conditionalTimo Teras2009-07-291-4/+7
| | | | | and force checksumming only when unpacking archive. otherwise it's extra computation for nothing.
* tar: don't call digest finalization twiceTimo Teras2009-07-291-0/+3
| | | | | otherwise bad things happens. avoid this be checking end of stream at the beginning of read.
* archive: append .apk-new to hard link targetsNatanael Copa2009-07-231-1/+5
| | | | Otherwise will link(2) fail since it does not exist.
* various: more informative error messagesTimo Teras2009-07-221-10/+11
|
* various: installation fixesTimo Teras2009-07-221-1/+2
| | | | | | | | - extract everything as .apk-new and overwrite only after data has been checksummed - url construction fixes (to work with simple http servers) - end of gunzip stream fixed - remove oneshot digesting flag for now as it's usage was broken
* various: fix installation of new style apksTimo Teras2009-07-211-1/+1
|
* pkg: fix indexing of multi-part apksTimo Teras2009-07-211-3/+3
|
* db: fixes to package checksumming while installing itTimo Teras2009-07-211-7/+12
|
* db: signed index loading (ref #46)Timo Teras2009-07-201-0/+5
| | | | prefer index in the new format as signed .tar.gz.
* archive: use the abuild-tar mangled checksum if availableTimo Teras2009-07-161-8/+28
| | | | to speed up apk installation avoid calculating checksums.
* various: new style index generationTimo Teras2009-07-161-12/+27
| | | | | | change the index generation to do old index, or the new style index where package identity is sha1 of control block and it's contained within an .tar.gz to allow signing in future.
* gzip: always autoclose the inner streamTimo Teras2009-07-161-13/+0
|
* db: live with sha1 and md5Timo Teras2009-07-141-9/+82
| | | | this also convers scripts file to a tar archive.
* blob: some helpers to replace snprintfTimo Teras2009-07-141-1/+1
| | | | | snprintf is dog slow. make the blob stuff have some helper functions so we can use them in code paths that are executed often.
* bstream: make tokenizable and load index using bstreamTimo Teras2009-07-141-1/+6
| | | | some fixes on index reading code too.
* io: move csumming away from bstream to gunzipTimo Teras2009-07-131-2/+2
| | | | | in future we want to checksum on gzip boundary basis, not the full file.
* archive: utimes modifies file, not link so don't use it for symlinksTimo Teras2009-01-171-7/+9
|
* archive: preserve mtime on extractionapk-tools-2.0_pre4Timo Teras2009-01-171-8/+27
|
* archive: set suid bit after chown if neededNatanael Copa2009-01-171-0/+6
| | | | chown will reset the suid bit so we need to set it again.
* various: make fancy progress bar and update todoTimo Teras2009-01-071-2/+4
|
* io: fix some memory leaksTimo Teras2009-01-061-1/+8
|
* archive: minor clean upsTimo Teras2009-01-061-2/+3
|
* io: apk_ostream stuffTimo Teras2008-11-281-5/+1
|
* db: checksum installed files, protect config filesTimo Teras2008-11-141-19/+13
| | | | | | | Checksum of installed is computed on the fly when extracting them and it'll be saved to fdb. When installing config files those are diverted with suffix .apk-new if earlier version of same file with local changes exist.
* use zlib internally to decompressTimo Teras2008-11-071-175/+66
|
* give more helpful error messagesNatanael Copa2008-10-261-0/+3
|
* Preserve uid and gid. Quiet flag to print dots on progress.Timo Teras2008-04-221-6/+11
|
* Argument parsing. Some other stuff too.Timo Teras2008-04-211-1/+1
|
* Initial commit of some stuff written so far. Still in state of flux. ExpectTimo Teras2008-04-171-0/+349
breakage and major changes.