summaryrefslogtreecommitdiff
path: root/src/apk_database.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/apk_database.h')
-rw-r--r--src/apk_database.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/apk_database.h b/src/apk_database.h
index 690b757..37dc557 100644
--- a/src/apk_database.h
+++ b/src/apk_database.h
@@ -35,6 +35,7 @@
#endif
#define APK_MAX_REPOS 32
+#define APK_MAX_TAGS 16
#define APK_CACHE_CSUM_BYTES 4
extern const char * const apk_index_gz;
@@ -121,6 +122,9 @@ struct apk_db_options {
struct list_head repository_list;
};
+#define APK_DEFAULT_REPOSITORY_TAG 0
+#define APK_DEFAULT_PINNING_MASK BIT(APK_DEFAULT_REPOSITORY_TAG)
+
struct apk_repository_tag {
unsigned int allowed_repos;
apk_blob_t *name;
@@ -143,7 +147,7 @@ struct apk_database {
struct apk_dependency_array *world;
struct apk_string_array *protected_paths;
struct apk_repository repos[APK_MAX_REPOS];
- struct apk_repository_tag repo_tags[APK_MAX_REPOS];
+ struct apk_repository_tag repo_tags[APK_MAX_TAGS];
struct apk_id_cache id_cache;
struct {
@@ -173,7 +177,7 @@ typedef union apk_database_or_void {
struct apk_name *apk_db_get_name(struct apk_database *db, apk_blob_t name);
struct apk_name *apk_db_query_name(struct apk_database *db, apk_blob_t name);
int apk_db_get_tag_id(struct apk_database *db, apk_blob_t tag);
-int apk_db_get_tag_id_by_repos(struct apk_database *db, unsigned int repos);
+
struct apk_db_dir *apk_db_dir_query(struct apk_database *db,
apk_blob_t name);
struct apk_db_file *apk_db_file_query(struct apk_database *db,