0

I'm making a personal build of LineageOS 17.0 that I want to include a number of pre-built APKs in. To achieve this, I have a separate folder "vendor/apps" which has two files apps-vendor.mk and Android.mk, and a sub-folder "app" which I store the APK files. This was with the help of this thread Add prebuilt apk to AOSP build.

Now, whilst I have been successful with including a number of APKs such as Blokada, FDroid, every now and then I come across an APK that I simply can't add into the build, such as TotalCommander.

If I go through the normal build process, it simply doesn't get added. If I use e.g. "mma TotalCommander" I receive an error saying "FAILED: ninja: unknown target 'TotalCommander'".

The following is what I have included in my apps-vendor.mk file:

    Blokada \
    FDroid \
    F-DroidPrivilegedExtension \
    VLC \
    WaveUp \
    YouTubeVancedMicroG \
    YouTubeVanced \
    TotalCommander

This is an excerpt from my Android.mk file:


# Custom added apps
include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := Blokada
LOCAL_CERTIFICATE := PRESIGNED
LOCAL_SRC_FILES := app/Blokada.apk
LOCAL_MODULE_CLASS := APPS
LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX)
include $(BUILD_PREBUILT)

include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := FDroid
LOCAL_CERTIFICATE := PRESIGNED
LOCAL_SRC_FILES := app/FDroid.apk
LOCAL_MODULE_CLASS := APPS
LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX)
include $(BUILD_PREBUILT)

include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := TotalCommander
LOCAL_CERTIFICATE := PRESIGNED
LOCAL_SRC_FILES := app/TotalCommander.apk
LOCAL_MODULE_CLASS := APPS
LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX)
include $(BUILD_PREBUILT)

etc ...

I have tried a few different things, such as swapping the APK filename for one that is working, trying a different module name such as TC, etc, all of which give the same result.

NZedPred
  • 11
  • 3

1 Answers1

1

I feel silly, but the issue was this. I originally had the folder directly under vendor, but then I moved the folder to a parent directory and symlinked it. Building does not work properly with symlinks like this. I still detects the vendor-apps.mk file, and when it is changed, but it doesn't actually add any rules.

NZedPred
  • 11
  • 3