[Android Q&A, Help & Troubleshooting] sonS30:
Custom Recovery

Is it possible to compile a custom recovery from the above stated firmware (LTE_D0201121.0_S30_0.021.01_8G_DS_user_SD.ZIP)? I would like to use it to get the phone rooted. Please, tell me if not.

I am not a developer, but have some basic knowledge. I setup the build environment for CyanogenMod 12.1 and tried to compile a custom recovery with CWM. Well the size of the boot.img seems reasonable, but the recovery.zip has only a few kilobytes. Maybe I am still missing some important information. Can anyone please check the output of the "make -j4 recoveryzip" command, and give me some hints where I still have something wrong?

sonS30@QWERTZUIOPÜ:~\android$ make -j4 recoveryzip
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=5.1.1
CM_VERSION=12.1-20171230-UNOFFICIAL-CatS30
TARGET_PRODUCT=cm_CatS30
TARGET_BUILD_VARIANT=eng
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a-neon
TARGET_CPU_VARIANT=cortex-a7
TARGET_2ND_ARCH=
TARGET_2ND_ARCH_VARIANT=
TARGET_2ND_CPU_VARIANT=
HOST_ARCH=x86_64
HOST_OS=linux
HOST_OS_EXTRA=Linux-4.10.0-42-generic-x86_64-with-Ubuntu-16.04-xenial
HOST_BUILD_TYPE=release
BUILD_ID=LMY49J
OUT_DIR=\home\sonS30\android\out
============================================
build\core\binary.mk:745: target '\home\sonS30\android\out\target\product\CatS30\obj\STATIC_LIBRARIES\libc_bionic_intermediates\arch-arm\bionic\memcmp.o' given more than once in the same rule
"ebtables is disabled on this build"
find: ‘dummy’: No such file or directory
PRODUCT_COPY_FILES device\generic\goldfish\data\etc\apns-conf.xml:system\etc\apns-conf.xml ignored.
No private recovery resources for TARGET_DEVICE CatS30
build\core\tasks\kernel.mk:121: ***************************************************************
build\core\tasks\kernel.mk:122: * Using prebuilt kernel binary instead of source *
build\core\tasks\kernel.mk:123: * THIS IS DEPRECATED, AND WILL BE DISCONTINUED *
build\core\tasks\kernel.mk:124: * Please configure your device to download the kernel *
build\core\tasks\kernel.mk:125: * source repository to kernel\Cat\CatS30
build\core\tasks\kernel.mk:126: * See http:\\wiki.cyanogenmod.org\w\Doc:_integrated_kernel_building
build\core\tasks\kernel.mk:127: * for more information *
build\core\tasks\kernel.mk:128: ***************************************************************
build\core\tasks\kernel.mk:333: warning: overriding recipe for target '\home\sonS30\android\out\target\product\CatS30\kernel'
build\core\Makefile:46: warning: ignoring old recipe for target '\home\sonS30\android\out\target\product\CatS30\kernel'
target thumb C: mount.exfat_static <= external\exfat\main.c
target StaticExecutable: mount.exfat_static (\home\sonS30\android\out\target\product\CatS30\obj\RECOVERY_EXECUTABLES\mount.exfat_static_intermediates\LINKED\mount.exfat)
target Symbolic: mount.exfat_static (\home\sonS30\android\out\target\product\CatS30\symbols\recovery\root\sbin\mount.exfat)
target Strip: mount.exfat_static (\home\sonS30\android\out\target\product\CatS30\obj\RECOVERY_EXECUTABLES\mount.exfat_static_intermediates\mount.exfat)
Install: \home\sonS30\android\out\target\product\CatS30\recovery\root\sbin\mount.exfat
target thumb C++: recovery <= bootable\recovery\recovery.cpp
target thumb C++: recovery <= bootable\recovery\bootloader.cpp
target thumb C++: recovery <= bootable\recovery\install.cpp
bootable\recovery\install.cpp: In function 'int really_install_package(const char*, int*, bool)':
bootable\recovery\install.cpp:199:1: warning: argument 'path' might be clobbered by 'longjmp' or 'vfork' [-Wclobbered]
really_install_package(const char *path, int* wipe_cache, bool needs_mount)
^
target thumb C++: recovery <= bootable\recovery\roots.cpp
target thumb C++: recovery <= bootable\recovery\ui.cpp
target thumb C++: recovery <= bootable\recovery\screen_ui.cpp
target thumb C++: recovery <= bootable\recovery\messagesocket.cpp
target thumb C++: recovery <= bootable\recovery\asn1_decoder.cpp
target thumb C++: recovery <= bootable\recovery\verifier.cpp
target thumb C++: recovery <= bootable\recovery\adb_install.cpp
target thumb C++: recovery <= bootable\recovery\default_device.cpp
target thumb C: recovery <= bootable\recovery\fuse_sdcard_provider.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\dynarray.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\getprop.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\newfs_msdos.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\setprop.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\start.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\stop.c
target thumb C: recovery <= bootable\recovery\..\..\system\core\toolbox\wipe.c
target thumb C: recovery <= bootable\recovery\..\..\system\vold\vdc.c
target StaticExecutable: recovery (\home\sonS30\android\out\target\product\CatS30\obj\EXECUTABLES\recovery_intermediates\LINKED\recovery)
target Symbolic: recovery (\home\sonS30\android\out\target\product\CatS30\symbols\system\bin\recovery)
target Strip: recovery (\home\sonS30\android\out\target\product\CatS30\obj\EXECUTABLES\recovery_intermediates\recovery)
----- Making recovery image ------
Copying baseline ramdisk...
Modifying ramdisk contents...
cp: cannot stat '\home\sonS30\android\out\target\product\CatS30\root\init.recovery.*.rc': No such file or directory
build\core\Makefile:944: recipe for target '\home\sonS30\android\out\target\product\CatS30\ramdisk-recovery.img' failed
make: [\home\sonS30\android\out\target\product\CatS30\ramdisk-recovery.img] Error 1 (ignored)
\home\sonS30\android\out\target\product\CatS30\recovery.img maxsize=123564672 blocksize=135168 total=9957376 reserve=1351680
Made recovery image: \home\sonS30\android\out\target\product\CatS30\recovery.img
----- Making recovery zip -----
.\build\tools\device\mkrecoveryzip.sh \home\sonS30\android\out\target\product\CatS30 \home\sonS30\android\out\host\linux-x86\framework\signapk.jar
cp: cannot stat '\home\sonS30\android\\home\sonS30\android\out\target\product\CatS30\recovery\root\etc': No such file or directory
cp: cannot stat '\home\sonS30\android\\home\sonS30\android\out\target\product\CatS30\recovery\root\sbin': No such file or directory
cp: cannot stat '\home\sonS30\android\\home\sonS30\android\out\target\product\CatS30\recovery\root\res': No such file or directory
cp: cannot stat '\home\sonS30\android\\home\sonS30\android\out\target\product\CatS30\system\bin\updater': No such file or directory
zip -ry \home\sonS30\android\\home\sonS30\android\out\target\product\CatS30\utilities\unsigned.zip . -x *\[* *\[\[*
adding: META-INF\ (stored 0%)
adding: META-INF\com\ (stored 0%)
adding: META-INF\com\google\ (stored 0%)
adding: META-INF\com\google\android\ (stored 0%)
adding: META-INF\com\google\android\updater-script (deflated 51%)
Recovery FakeFlash is now available at \home\sonS30\android\\home\sonS30\android\out\target\product\CatS30\utilities\update.zip

#### make completed successfully (01:03 (mm:ss)) ####