Common: renames androidApi.h for android/api.h

This commit is contained in:
李通洲
2026-09-18 20:24:43 +08:00
parent e1d7360453
commit 2594c01fc1
5 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
#include "fastfetch.h"
#include "battery.h"
#include "common/androidApi.h"
#include "common/android/api.h"
#include "common/android/binder.h"
#include "common/processing.h"
#include "common/properties.h"
+1 -1
View File
@@ -42,7 +42,7 @@ static void ffCameraMaxStreamSize(const ACameraMetadata* metadata, int32_t forma
const char* ffDetectCamera(FFlist* result) {
// The camera2 NDK and every entry point below were introduced in API 24, which is the API level
// this build targets, so nothing here is newer than the minimum supported version and
// common/androidApi.h has nothing to guard. That header covers the opposite case: entry points
// common/android/api.h has nothing to guard. That header covers the opposite case: entry points
// the NDK marks unavailable because they postdate the target, such as AImageDecoder (30) or
// AMediaCodec_getName (28). It also only ever makes *symbols* weak -- libcamera2ndk.so itself is
// API 24, so linking it unconditionally in CMakeLists.txt is fine on every supported device.
+1 -1
View File
@@ -1,6 +1,6 @@
#include "codec.h"
#include "common/androidApi.h"
#include "common/android/api.h"
#include "common/strutil.h"
#include <media/NdkMediaCodec.h>
+2 -2
View File
@@ -1,6 +1,6 @@
#include "image.h"
#include "common/androidApi.h"
#include "common/android/api.h"
#include "common/io.h"
#include "common/mallocHelper.h"
@@ -122,7 +122,7 @@ FF_REQUIRES_API(30) static bool androidResolveDecoder(AImageDecoder* decoder, FF
bool ffImageCreateAID(FFLogoRequestData* requestData, FFImageBuffer* out, const char** error) {
// AImageDecoder is API 30, and fastfetch still runs on devices below that, so this is a real
// run-time check and not a compile-time constant. See common/androidApi.h for why.
// run-time check and not a compile-time constant. See common/android/api.h for why.
if (FF_API_AT_LEAST(30)) {
FF_AUTO_CLOSE_FD int fd = open(instance.config.logo.source.chars, O_RDONLY | O_CLOEXEC);
if (fd < 0) {