Showing posts with label Compiling. Show all posts
Showing posts with label Compiling. Show all posts

Wednesday, 20 July 2016

Linux Header On Kernel/ Compiling kernel



Hello, I was trying to do pentesting on my device through kali linux 2.0. I successfully installed kali linux via linix deploy ,but i was unable to use reaver as my chipset doesn't support monitor mode. So I tried to use external usb wifi adapter( tplink tl wn 722n, chipset atheros ar9271). I tried to install driver myself but when i gave make command i found this error:
make defconfig-ath9k
root@localhost:/usr/src/backports-3.15-rc1-1# make defconfig-ath9k
/--------------
| Your kernel headers are incomplete/not installed.
| Please install kernel headers, including a .config
| file or use the KLIB/KLIB_BUILD make variables to
| set the kernel to build against, e.g.
| make KLIB=/lib/modules/3.1.7/ | to compile/install for the installed kernel 3.1.7
| (that isn't currently running.) \--
Makefile:40: recipe for target 'defconfig-ath9k' failed make: *** [defconfig-ath9k] Error 1
CAN ANYONE HELP ME HOW TO OVERCOME THIS? HOW TO COMPILE KERNEL IN THIS SPECIFIC CASE ?Or HOW TO ENABLE MONITOR MODE WITH AR9271 CHIPSET?
MY KERNEL IS 3.10.54+



Sunday, 17 July 2016

Compiling Kernel



I tried to compile kernel from official CM github, but I end up with this errors:


Code:


make[1]: Nothing to be done for 'dtbs'.
make[1]: Nothing to be done for 'dtbs'.
  GZIP    arch/arm64/boot/Image.gz
make[1]: *** No rule to make target 'arch/arm64/boot/dts/msm8956-mtp.dtb', needed by 'arch/arm64/boot/Image.gz-dtb'.  Stop.
/home/yaw/android/kenzo/android_kernel_xiaomi_msm8956/arch/arm64/Makefile:84: recipe for target 'Image.gz-dtb' failed
make: *** [Image.gz-dtb] Error 2


Anyone can help me fix this error?

Million Thanks :)



Thursday, 14 July 2016

Cannot flash system after compiling it from source



Hello
I compiled android for Volantis ( after downloading the sources from official google repo )
when trying to flash it i have this message
i added the "-S 256M" after finding it online , it didn't work without it too , i think that it doesn't flash the whole image since the image size is 1.5G .
I successfully flash the stock image though .

Code:


fastboot flash -S 256M system system.img

gives this output :

Code:


Invalid sparse file format at header magi
erasing 'system'...
OKAY [  0.954s]
sending sparse 'system' (233172 KB)...
OKAY [ 11.755s]
writing 'system'...
(bootloader) Device State : Unlocked
OKAY [  7.615s]
sending sparse 'system' (255959 KB)...
OKAY [ 12.817s]
writing 'system'...
(bootloader) Device State : Unlocked
OKAY [  8.801s]
sending sparse 'system' (62570 KB)...
OKAY [  3.364s]
writing 'system'...
(bootloader) Device State : Unlocked
OKAY [  2.531s]
finished. total time: 47.838s


If anyone has had this problem before and knows the solution , i would be grateful :)



Monday, 4 July 2016

[PROBLEM] Compiling Omni from source fails



Hi,

I was trying to compile Omni 6.0.1 from source for a Samsung Galaxy Grand Prime [ gprimeltevl ], and the process was halting when validatekeymaps was about to be built.
I wanted to post this in Miscellaneous Android Development section but I'm still new so i couldn't.

Here is the console output of make:


Code:


root@arch-Vinny:/mnt/android/omni/frameworks/base/tools# m -j8 -C /mnt/android/omni/
make: Entering directory '/mnt/android/omni'
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=6.0.1
TARGET_PRODUCT=full_gprimeltevl
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a-neon
TARGET_CPU_VARIANT=cortex-a53
TARGET_2ND_ARCH=
TARGET_2ND_ARCH_VARIANT=
TARGET_2ND_CPU_VARIANT=
HOST_ARCH=x86_64
HOST_OS=linux
HOST_OS_EXTRA=Linux-4.6.2-1-ARCH-x86_64-with-Ubuntu-15.10-wily
HOST_BUILD_TYPE=release
BUILD_ID=MOB30M
OUT_DIR=/mnt/android/omni/out
============================================
including ./abi/cpp/Android.mk ...
including ./art/Android.mk ...
including ./bionic/Android.mk ...
including ./bootable/recovery/Android.mk ...
/bin/bash: line 0: test: -ge: unary operator expected
/bin/bash: line 0: test: -ge: unary operator expected
 
. .
. .
. .

including ./system/security/keystore-engine/Android.mk ...
including ./system/security/keystore/Android.mk ...
including ./system/security/softkeymaster/Android.mk ...
including ./system/vold/Android.mk ...
including ./vendor/omni/Android.mk ...
including ./vendor/samsung/fortuna/Android.mk ...
including ./vendor/samsung/gprimeltevl/Android.mk ...
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/bluetooth/auto_pair_devlist.conf'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/bluetooth/auto_pair_devlist.conf'
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/bluetooth/bt_did.conf'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/bluetooth/bt_did.conf'
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/bluetooth/bt_stack.conf'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/bluetooth/bt_stack.conf'
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/lib/libaudioroute.so'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/lib/libaudioroute.so'
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/lib/libminui.so'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/lib/libminui.so'
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/lib/libtinyalsa.so'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/lib/libtinyalsa.so'
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/vendor/etc/audio_effects.conf'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/vendor/etc/audio_effects.conf'
PRODUCT_COPY_FILES device/samsung/gprimeltevl/configs/msm_irqbalance.conf:system/vendor/etc/msm_irqbalance.conf ignored.
build/core/Makefile:72: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/wifi/wpa_supplicant.conf'
build/core/base_rules.mk:559: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/system/etc/wifi/wpa_supplicant.conf'
No private recovery resources for TARGET_DEVICE gprimeltevl
device/samsung/gprimeltevl/mkbootimg.mk:20: warning: overriding recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/boot.img'
build/core/Makefile:580: warning: ignoring old recipe for target '/mnt/android/omni/out/target/product/gprimeltevl/boot.img'
build/core/tasks/kernel.mk:104: ***************************************************************
build/core/tasks/kernel.mk:105: * Using prebuilt kernel binary instead of source              *
build/core/tasks/kernel.mk:106: * THIS IS DEPRECATED, AND WILL BE DISCONTINUED                *
build/core/tasks/kernel.mk:107: * Please configure your device to download the kernel        *
build/core/tasks/kernel.mk:108: * source repository to kernel/samsung/gprimeltevl
build/core/tasks/kernel.mk:109: * See http://forum.xda-developers.com/wiki/ROM/Integrated_Kernel_Build
build/core/tasks/kernel.mk:110: * for more information                                        *
build/core/tasks/kernel.mk:111: ***************************************************************
Import includes file: /mnt/android/omni/out/host/linux-x86/obj/EXECUTABLES/validatekeymaps_intermediates/import_includes
make: *** No rule to make target 'NOTICE-HOST-STATIC_LIBRARIES-libinput', needed by '/mnt/android/omni/out/host/linux-x86/bin/validatekeymaps'.  Stop.
make: *** Waiting for unfinished jobs....
Export includes file: frameworks/base/tools/validatekeymaps/Android.mk -- /mnt/android/omni/out/host/linux-x86/obj/EXECUTABLES/validatekeymaps_intermediates/export_includes
make: Leaving directory '/mnt/android/omni'

#### make failed to build some targets (57 seconds) ####

root@arch-Vinny:/mnt/android/omni/frameworks/base/tools#


I'm still a bit new to Android development; this is my first foray into ROM building, though I am experienced in C and am familiar with Java, C++ though I'm not that good with Makefiles. I've been stuck at this point for days, any sort of help would be appreciated at all. Thanks.