diff options
author | Ariadne Conill <ariadne@dereferenced.org> | 2022-01-13 08:19:36 -0600 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2022-03-30 09:17:25 +0000 |
commit | fee0587660993f85111ac8bb0cde3bf159936be2 (patch) | |
tree | 8eb57710bce1fec14b0ce0eddb891316a61b7135 /src | |
parent | 8051d458c61a8b250c4be256b85b5d67e2b592ac (diff) | |
download | apk-tools-fee0587660993f85111ac8bb0cde3bf159936be2.tar.gz apk-tools-fee0587660993f85111ac8bb0cde3bf159936be2.tar.bz2 apk-tools-fee0587660993f85111ac8bb0cde3bf159936be2.tar.xz apk-tools-fee0587660993f85111ac8bb0cde3bf159936be2.zip |
defines: introduce APK_DEFAULT_ABI_TAG
for most cases, this replaces APK_DEFAULT_ARCH. if apk-tools is built without
a configured abi-tag, the ABI tag is equivalent to APK_DEFAULT_ARCH, providing
backwards compatibility with apk v2
the /etc/apk/arch configuration file is assumed to actually describe an ABI
tag.
Diffstat (limited to 'src')
-rw-r--r-- | src/apk_defines.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/apk_defines.h b/src/apk_defines.h index 9cacf13..e7fe34c 100644 --- a/src/apk_defines.h +++ b/src/apk_defines.h @@ -142,6 +142,12 @@ static inline int IS_ERR(const void *ptr) { return (unsigned long)ptr >= (unsign #error APK_DEFAULT_ARCH not detected for this architecture #endif +#ifndef APK_ABI_TAG +#define APK_DEFAULT_ABI_TAG APK_DEFAULT_ARCH +#else +#define APK_DEFAULT_ABI_TAG APK_ABI_TAG "-" APK_DEFAULT_ARCH +#endif + #define APK_MAX_REPOS 32 /* see struct apk_package */ #define APK_MAX_TAGS 16 /* see solver; unsigned short */ #define APK_CACHE_CSUM_BYTES 4 |