apk --help will list the generic options only and give a list of commands
To get the details for a spefic command, 'apk command --help' should be used.
fixes#42
This will also fix a bug that left an empty file in destination dir when
source file did not exist in repository.
There are still issues with paths longer than 255 chars.
By locking all the given dependendencies for virtual packages first
we can catch invalid deps and report those. This is alot more helpful
than just reporting "Unable to install <virutalpkg>"
implements 'apk add --virutal metaname dep1 dep2...' where metaname will
be an empy meta package with dep1 and dep2 as dependencies.
This is useful to prevent abuild to add each makedepend to world which
causes some headache when it comes to unintalling them after sucessful build.
The syntax is: apk index -d /path/to/APK_INDEX.gz pkg...
It does not seem like its possible to remove packages in the db so we
trick apk_db_index_write() by setting the repo to on-zero.
It's still not perfect since it does not recalculate the dependencies.
The state size is taken from name_id and cannot be extended. So we
must wait with initializing the state til we have all packages added
to the db.
We must also always allocate the package name, incase its not in the
repository. This is done with apk_db_get_name().
This allows you to query the state db even if you do not have write
permissions in cache dir (which is needed if you have remote repositories)
This should speed up things and save some memory if you have big and slow
remote repositories.
apk_db_add_repository does its own error reporting and does not set errno
reliable. This patch also tell which repository it failed to load the index
for rather than just say it failed to open "APK_INDEX.gz" which does not tell
much.
Tracks now probler header file dependencies and command line parameters
used to build files. E.g. changing CFLAGS rebuild all C-files. And changing
version rebuild now the files where it's used.