[Q] Rebuilding safestrap / twrp? - Motorola Droid Bionic

Has anyone tried rebuilding Safestrap for the bionic?
Source is here:
https://github.com/Hashcode/android_bootable_recovery
The readme.md points you to the TWRP build thread:
http://forum.xda-developers.com/showthread.php?t=1943625
I have CM10.1 installed in ~/android/system. I've been building and loading it on my bionic, and that's working fine. Per TWRP instructions, I also rebuilt CWM recovery without error (make clean && make recoveryimage).
Reading through the TWRP instructions, it calls for replacing your bootable/recovery CWM image with the TWRP build tree. Rather than do this, I instead wanted to pull down SafeStrap's git repo into its own dir seperate from the CM10.1 build tree (for my own sanity), and use a symlink to make it look like I had.
I cloned the safestrap repo into ~/android/safestrap/android_bootable_recovery.
I renamed my ~/android/system/bootable/recovery directory (to recovery.orig) and symlink'd so that ~/android/system/bootable/recovery maps to ~/android/safestrap/android_bootable_recovery).
When I try to build (make clean && make recoveryimage), I get a couple of errors right away:
bootable/recovery/Android.mk:18: bootable/recovery/../../external/safestrap/safestrap.mk: No such file or directory
build/core/base_rules.mk:123: *** bootable/recovery: LOCAL_BUILT_MODULE and LOCAL_INSTALLED_MODULE must not be defined by component makefiles. Stop.
There is no ~/android/system/external/safestrap directory for that safestrap.mk. A find command shows that safestrap.mk doesn't exist in either ~/android/system/external, or in the SafeStrap source.
I have been assuming that CM10.1 targa branch was safestrap friendly, but I don't see any of the TWRP switches in any of the BoardConfig.mk files or anywhere else for that matter.
Is there a special CM10.1 branch that includes these TWRP-friendly tweaks, or are they sitting in someone's working copy...? If so, anyone care to share them?
In return, I'll write up a good build summary and perhaps we can get hashofcodes to add it to the readme.md...?
Thanks,
- Josh.

Related

CM9 boot.img source

Hi,
Could anybody tell me which are the bare minimum sources needed to compile a working cyoanogenmod 9 kernel boot.img?
I'm currently trying to compile one on my own but I can't afford to download the whole CM9 source due to the internet contract i have.
Thanks
Nobody? Ok then... May someone please copy and paste their makefile inside the root directory of his Android tree? (the one from wich they issue the command "make -j4 out/target/product/galaxysmtd/boot.img").
Maybe you could try cloning the android_build project and the teamhacksung buildscript project as well. Then adjust the buildscripts to point to the correct toolchain directory...
Boot.img contains the kernel. Therefore you need the kernel sources since at cm9 the kernel is build while compiling cm. You can find that sources at github (in project kernel_samsung_aries or something). You need to put this directory to your root directory of your android build system (there you have the device dir, frameworks, vendor etc). Rename it into kernel/samsung/aries. Then you should be able to build. It has worked like this for i9001, and it should also for i9000
You could also look at the kernel source of semaphore/devil. They use their own build script which does not require the full cm9 source, but only the kernel source. I made an adapted version of their scripts to build my own kernel...
Verstuurd van mijn GT-I9000
I think he already has:
__Pol__ said:
Nobody? "make -j4 out/target/product/galaxysmtd/boot.img"
Click to expand...
Click to collapse
Thanks everybody!
Sorry if the first two posts misled you.
I already have the kernel source. What I need are some instructions in order to build the boot.img from them. I can't download the whole source branch because I'm on a data diet .
Also a copy paste of the main make file is accepted.
I think this could help you:
http://forum.xda-developers.com/showthread.php?p=28096022
It's again for i9001 (sorry, but I own one ), but should also work
I think this could help you:
http://forum.xda-developers.com/show...php?p=28096022
It's again for i9001 (sorry, but I own one ), but should also work
Click to expand...
Click to collapse
Thanks. I've already tried the split_bootimg.pl but it did not work. According to sbuild.sh from semaphore kernel what i need to do is just "cp bzImage boot.img". I had already done it before but my phone did not boot up. It showed the bootloader logo but then nothing so something is wrong with the initramfs. Is the one included with the kernel sources correct or am I missing something?
So you can build the kernel? And just copying the kernel image to boot.img won't work. As you can see in the splitted boot.img from arco or anyone else, there are some other things needed.
I think you need to split it, replace the kernel image (zImage I thinl) and put all files again together (including the other files from the working boot.img).
No warranty on that, but that's what I understood
hahnjo said:
So you can build the kernel? And just copying the kernel image to boot.img won't work. As you can see in the splitted boot.img from arco or anyone else, there are some other things needed.
I think you need to split it, replace the kernel image (zImage I thinl) and put all files again together (including the other files from the working boot.img).
No warranty on that, but that's what I understood
Click to expand...
Click to collapse
Actually I can't split the boot.img because split_bootimg.pl does not work. The problem is in the initramfs and that is why I was asking for some advice about the sources needed. The auto-generated initramfs does not work.
__Pol__ said:
Actually I can't split the boot.img because split_bootimg.pl does not work. The problem is in the initramfs and that is why I was asking for some advice about the sources needed. The auto-generated initramfs does not work.
Click to expand...
Click to collapse
When I tried it, it worked... Are you sure that you have Pearl installed. Which OS do you use?
How do you generate initramfs?
I'm running Debian wheezy, pearl is installed. The script says it has not found android magic. The initramfs is automatically generated by the kernel source. I fear some files are missing here: https://github.com/CyanogenMod/android_kernel_samsung_aries
Do I need to get *bootimg from here?
https://github.com/CyanogenMod/android_device_samsung_aries-common
If yes how do I use these 2 scripts?
Sorry they're not two scripts but a script and a make file. From where does that makefile obtain the variables?
For splitting, did you use a running boot.img, e.g. from CM9 for your device?
You have two possibilities for building a running boot.img:
1) It is builded if you compile CM or AOSP or another ROM from Source (therefore you would need the complete sources)
2) You only build the Kernel and put it in an existing boot.img (for your phone of course) by just replacing the kernel.
For second you need to split an existing boot.img
Hi
Sent from my GT-S5830 using xda app-developers app
hahnjo said:
For splitting, did you use a running boot.img, e.g. from CM9 for your device?
You have two possibilities for building a running boot.img:
1) It is builded if you compile CM or AOSP or another ROM from Source (therefore you would need the complete sources)
2) You only build the Kernel and put it in an existing boot.img (for your phone of course) by just replacing the kernel.
For second you need to split an existing boot.img
Click to expand...
Click to collapse
Well, actually there's a third method. I need the initramfs source, the kernel source and the recovery source. After building I need to pack them together. Until yesterday I had only the sources for kernel and initramfs (?). Now I'll head for some sources for the recovery but I still need the main makefile (inside the Android directory) to know what commands I have to issue.
Sorry guys if I stil can't explain my problem to you. I really appreciate your patience and your helpful tips though.
You could look at devil/semaphore, as they use a complete initramfs, including recovery (both have a slightly different implementation).
Verstuurd van mijn GT-I9000
kasper_h said:
You could look at devil/semaphore, as they use a complete initramfs, including recovery (both have a slightly different implementation).
Verstuurd van mijn GT-I9000
Click to expand...
Click to collapse
Yep! I had a look there and I understood I was missing the recovery. Semaphore uses a custom amde initramfs and recovery whith load of scripts I don't need. I downloaded the CWM source from cyanogenmod git. There is only an Android.mk that obviously won't work. The question still remains: has anybody here downloaded the whole cyanogenmod source? If yes, may they post the makefile here please?
I have the whole CM sources, CM7 and CM9. Atm I can't access them because I'm on travel. I will return next week, maybe then.
Though, I think that it is impossible to extract the needed Makefiles. The Main-Makefile includes another makefile, but from then on several files are included which include again files. I stopped trying to understand it after the first 3 files...

[Q] Nook HD/HD+ how to build u-boot

Hi, i am trying to build a simple u-boot that fast load kernel. I edited bootmode.c for hummingbird or ovation depending on which tablet i was testing. It looks like :
SORRY CANT POST LINK BUT IT WOULD HAVE BEEN:
github dot com/astarasikov/uboot-bn-nook-hd-fastboot/blob/master/board/bn_ovation/bootmode.c
Kernel command line for hummingbird :
vmalloc=768M init=/init rootwait omap_wdt.timer_margin=20 androidboot.hardware=hummingbird display.vendor=AUO boot.fb=b2600000
I replace uImage with the custom u-boot.bin i build no success.
I also tried to build the stock u-boot as provided by b&n or the one at :
SORRY CANT POST LINK BUT IT WOULD HAVE BEEN:
github dot com/fat-tire/u-boot-hummingbird-ovation
In this case i replaced the u-boot.bin with the u-boot.bin i generated (this one would load the second u-boot.bin that is uImage).
In all cases i used a working sdcard that can boot cyanogen fine with the provided u-boot.bin or uImage. Depending on which case i only replaced either u-boot.bin or uImage.
I tried building with several different toolchain :
debian-7.0.0-minimal-armel-2013-05-05.tar.xz
gcc-arm-none-eabi-4.4.1-2010q1-188-linux32.tar.gz (sourcery one)
gcc-linaro-4.4-2011.02-0.tar.bz2
gcc-linaro-arm-linux-gnueabi-2012.03-20120326_linux.tar.bz2
and android ics toolchain (gcc 4.4.3)
In no case i was able to build a working u-boot.bin (all compiled with proper path to toolchain with fully clean source tree and ARCH=arm and CROSS_COMPILE properly set). By the way i am able to build working kernel.
So what is it that i am missing ? Is there some magic patch to u-boot ?
Would appreciate any information, tips on what is it that i am doing wrong.
Thanks, keep up the good work.

[TOOL] NEW <<--->> OLD Bootloader ROM Converter v1.0

P990 ROM Converter
from New BootLoader to Old and vice versa​
Actually this tool is Tonyp’s idea. All credits to him.
He asked me if I am interested in making a script and automating the rom porting from one bootloader to the other and he assisted me with all the changes that need to be done.
Due to different EOL (end of line) termination in text files between UNIX-Linux (LF) and windows (CRLF), I had to make bash (linux) scripts necessarily. The good thing is that the tool can be used in both windows and linux systems.​Installation:
Download and extract the attached ROM-Converter-tools.zip package anywhere you like.
Download and extract in the same folder, a newer ROM-Converter-scripts.zip if exists.
For Windows systems only:
Install Cygwin following the instructions below:
Download setup-x86.exe from here http://cygwin.com/install.html
Attention!! Even if you are running x64 windows system install the x86 version. DO NOT install the x64 cygwin version because two binaries (mkbootfs.exe & mkbootimg.exe used to pack boot.img do not work properly).
Run the setup-x86.exe, when the list of packages is shown make sure you add the following:
Expand Archive and select zip & unzip to be installed
Expand Utils and select cpio to be installed
Expand Perl and select ‘perl: Larry Wall’s Practical..’ and perl_vendor to be installed
(If you are already using cygwin run setup again and add the above packages to be installed.)
For Linux systems only:
Download the attached linux-mkboot-binaries.zip (mkbootfs, mkbootimg), extract them in tool folder and remove the windows ones (mkbootfs.exe, mkbootimg.exe).​How to use it:
Put the source ROM.zip(s) in the 'source_zips' folder (otherwise you’ll be prompted to drag n’ drop it in terminal)
Open Cygwin. Type cd (leave a space after cd) and type /cygdrive/c/dir1/dir2/../ROM-Converter-tools
where “c/dir1/dir2/../ROM-Converter-tools” is the full path of the folder you extracted the convert-tool package (e.g C:\dir1\dir2\..\ROM-Converter-tools) and press enter.
In case of long pathname, instead of typing the whole of it, use one of the following tips to easily change to tool's path.
Tip#1: After you type cd , drag n’ drop from windows explorer into cygwin terminal, the folder "ROM-Converter-tools" and it wiil automatically be converted to ‘/cygdrive/c/dir1/dir2/../ROM-Converter-tools’ press enter and that’s it.
Tip#2: After cd /cygdrive/c/ type the 1st one or two letters of the next subdir and autocomplete it's name with TAB.
Type one of these commands in cygwin terminal:
Code:
./convert_rom.sh -stepmode #--> starts in step-mode for debugging purposes
./convert_rom.sh #--> runs unattended (with no pauses).
​What it does:
The scripts use as input the 'files2convert.txt' which contains all possible files needed to be converted.
This is for compatibility purposes to support as many roms as possible and for future changes.
files2convert.txt
Code:
/ramdisk/fstab.star
/ramdisk/fstab.p990
/ramdisk/init.cm.rc
/ramdisk/init.cm-star.rc
/ramdisk/init.star.rc
/system/etc/vold.fstab
/system/bin/setup-recovery
/system/bin/check_sdcard.sh
/META-INF/com/google/android/updater-script
More files can easily be added for conversion if needed.
The converter:
Extracts source ROM zip
Unpacks the boot.img
Reads the above files, replacing partitions' mount points, among some othe things, for the selected bootloader
Replaces the kernel image for the selected bootloader
Builds new boot.img
Creates new converted ROM zip
Under 'kernels' folder there are already included the two latest Kowalski kernel images (zImage) for old & new BL and its modules.
You can add more kernels and you’ll be prompted to choose the desired one when converting a ROM (if more than one is found ).
Read how to do this:
kernels folder contains all kernel images (zImage), kernel modules and any other file the kernel needs.
for each kernel there are:
file(s) named: prefix-KernelName[-ver].zImage
folder(s) named: [prefix-]KernelName[-ver]Kernel
where:
prefix must be oldbl or newbl (depending on which bootloader this kernel is for.
KernelName[-ver] is whatever you like [and optionaly its version].
zImage is the extension of the kernel image.
How to maintain kernels folder
A. Update existing kernels
Download the desired kernel package and open it.
Replace its kernel zIamge in kernels folder
Extract its modules and any other file needed and replace all existing ones
B. Add kernels
Download the kernel package and open it.
Find the zImage inside package and extract it into kernels
Rename it this format: prefix-KernelName[-ver].zImage
Create a folder named: prefix-KernelName[-ver]. It will be used to keep kernel's modules and other files needed. If this kernel is released for both bootloaders and its modules are identicaly on both bootloaders (like the existing kowalski one) then name the folder only KernelName[-ver] (without prefix).
Inside this [prefix-]KernelName[-ver] folder create a subdir tree lib\modules
Extract in lib\modules all kernel's modules from kernel package.
If any other file is needed by kernel then create it's subdir tree (assuming that [prefix-]KernelName is the system folder of the kernel package) and extract it there.
Attention: Current version will hopefully work on CM-based ROMs.
Stock based ROMs need more files to be changed, but they are not included yet, because I don't have the whole info needed.
Hopefully @rugglez or someone else will be willing to help.
Till then avoid converting stock-based roms, (or if you do try, then after converting replace the boot.img in converted rom and "system/lib/modules/*" at least with a working boot.img and modules from another stock-based rom, for this bootloader of course. This could work but I am not the expert to say)​
ChangeLog:
Version 1.0 Aug 23, 2013
- The two convert2xxx_bl.sh scripts are now integrated into one script convert_rom.sh.
- The new convert_rom.sh also accepts an optional switch [-stepmode].
Code:
./convert_rom.sh -stepmode #--> starts in step-mode for debugging purposes
./convert_rom.sh #--> runs unattended (with no pauses).
- A technique added to preserve whitespaces in converted lines. So converted files keep margins and whitespaces of the source ones.
- Script checks whether source rom is a newbl or an oldbl one, displays an error message if rom is not for the expected bootloader and exits.
Version 0.3b Aug 23, 2013
-a typo fixed in converting scripts
Version 0.2b Aug 23, 2013
-liblgeril.so is also replaced with the one for the oldbl or newbl accordingly.
-A forced removal (switch -f) added when removing files and dirs just in case.
-Converted ROM name will be built automatically from the source name suffixed by -oldbl or -newbl accordingly. (If source rom's name contains 'newbl' or 'oldbl' it will be substituted by 'oldbl' or 'newbl' accordingly)
-Converted ROMs are now created under 'converted_roms' folder.
-Converting to oldbl: Files 'check_sdcard.sh' and 'lgdrm.img' are being removed if exist (as they are not used)
-Converting to newbl: Charger dependent images are also copied in ramdisk (not only the charger binary).
-Kernel modules will also be replaced with the ones coming with specific kernel image.
-Kowalski Kernel images & modules, in kernels folder, are replaced with latest ones dated:2013072013. (it was my fault, the previous ones were downloaded from "releases" download folder and were dated 20230303)
-Some changes in display messages.
Version 0.1b Aug 19, 2013
-1st beta version​
I really don't want to have all of the credits.
While it's been my idea to create such a script and I provided the input on what needs to be changed by the script, I couldn't have done it on my own.
I both lack the skills(!) and time.
Steve would say:
Anyways, don't leech. If this helps someone, donations are appreciated:
Donate to spyrosk
Donate to me​
spyrosk said:
To convert a new-bl rom to an old-bl rom: Type ./convert2old_bl.sh
To convert an old-bl rom to a new-bl rom: Type ./ convert2new_bl.sh
​
Click to expand...
Click to collapse
Thanks Android tool guru @spyrosk....and thanks @tonyp
just trying it out. A small comment....people might mistake this....there is no space between the / AND convert2new_bl.sh command line....should be the same with oldbl.sh command....isnt it?
thought of giving a feedback about this.
thanks once again
EDIT: battery charge script cannot be opened error....and cannot be removed error....
Creating new ROM zip ... zip warning: Permission denied
zip warning: Permission denied
something went wrong please zip contents in rom folder manually
done.
SREEPRAJAY said:
Thanks Android tool guru @spyrosk....and thanks @tonyp
just trying it out. A small comment....people might mistake this....there is no space between the / AND convert2new_bl.sh command line....should be the same with oldbl.sh command....isnt it?
thought of giving a feedback about this.
thanks once again
EDIT: battery charge script cannot be opened error....and cannot be removed error....
Creating new ROM zip ... zip warning: Permission denied
zip warning: Permission denied
something went wrong please zip contents in rom folder manually
done.
Click to expand...
Click to collapse
Hi my friend,
First of all sorry again for deleted post(s)..
and thank you.
The "typo" is corrected. Actually it was not a typo but I have noticed that it happens when pasting text from another editor.
Which ROM did you try to convert?
battery charge script cannot be opened error??? On which step did it happen?
I don't try to open any battery charge script
Did you add any file in "files2convert.txt"?
Very interesting tool.
Last july 7th I asked you if this were possibile and didn't have any reply. Now I'm happy that Tonyp convinced you.
Sent from my LG-P990 using xda app-developers app
wals46 said:
Very interesting tool.
Last july 7th I asked you if this were possibile and didn't have any reply. Now I'm happy that Tonyp convinced you.
Sent from my LG-P990 using xda app-developers app
Click to expand...
Click to collapse
I was on vacation sorry and when I came back I forgot to reply.
By that time I couldn't tell for sure anyway, before I have the total "picture" of the work that must be done, I mean.
@spyrosk,
my friend
Which ROM did you try to convert? Latest Avatar 3.1 Nightly OLD to NEW BL
battery charge script cannot be opened error??? On which step did it happen?I don't try to open any battery charge script It happened just the step before making the new ROM Zip
Did you add any file in "files2convert.txt"? NO
Nevertheless, I will try to flash the ROM and see what happens
EDIT:
Just now, I tried to do the PAC Man by Metallica for the Old BL and had the same error of battery charge script....
Same in Django Adios Amigo 1.6.5 to OldBL....see the script error below:
STEP 2: EXTRACTING BOOT.IMG ...
Press [enter] when ready
rm: remove write-protected regular file `out/ramdisk/charger'?
rm: cannot remove `out/ramdisk': Directory not empty
mkdir: cannot create directory `out': File exists
STEP 5: PACKING NEW BOOT.IMG ...
Press [enter] when ready
Selected kernel: kernels/oldbl-Kowalski-126.zImage
Using base address 0x10000000
Using command line ''
error: cannot open './ramdisk/charger' for read
rm: remove write-protected regular file `out/ramdisk/charger'?
rm: cannot remove `out/ramdisk': Directory not empty
Hope this helps in checking....
SREEPRAJAY said:
@spyrosk,
my friend
Which ROM did you try to convert? Latest Avatar 3.1 Nightly OLD to NEW BL
battery charge script cannot be opened error??? On which step did it happen?I don't try to open any battery charge script It happened just the step before making the new ROM Zip
Did you add any file in "files2convert.txt"? NO
Nevertheless, I will try to flash the ROM and see what happens
EDIT:
Just now, I tried to do the PAC Man by Metallica for the Old BL and had the same error of battery charge script....
Same in Django Adios Amigo 1.6.5 to OldBL....see the script error below:
STEP 2: EXTRACTING BOOT.IMG ...
Press [enter] when ready
rm: remove write-protected regular file `out/ramdisk/charger'?
rm: cannot remove `out/ramdisk': Directory not empty
mkdir: cannot create directory `out': File exists
STEP 5: PACKING NEW BOOT.IMG ...
Press [enter] when ready
Selected kernel: kernels/oldbl-Kowalski-126.zImage
Using base address 0x10000000
Using command line ''
error: cannot open './ramdisk/charger' for read
rm: remove write-protected regular file `out/ramdisk/charger'?
rm: cannot remove `out/ramdisk': Directory not empty
Hope this helps in checking....
Click to expand...
Click to collapse
I just converted Avatar-3.1 from old to new. No errors at all.
I don't like the write-protected error: rm: remove write-protected regular file `out/ramdisk/charger'
So it tries after that to remove the out directory but of course it's not empty.
Well,
Remove out directory manually and try again from the beginning..
After step 5, Before you continue to next step try to remove the whole out directory manually again.
Try also to give your account full control to the converter's folder.
This problem seems to he a windows security permission issue. Are you an administrator on the system you use?
-------------------------------------------------------------------
Stock based ROMs need more files to be changed, but they are not included yet, because I don't have the whole info needed.
Hope @rugglez or someone else will be willing to help.
Till then avoid converting stock-based roms,( or after converting replace the boot.img in converted rom with a working boot.img from another stock-based rom for the same bootloader of course. This may work)
Try ONLY CM-based roms.
I forgot to write it in OP. I'll do it asap.
spyrosk said:
I just converted Avatar-3.1 from old to new. No errors at all.
I don't like the write-protected error: rm: remove write-protected regular file `out/ramdisk/charger'
So it tries after that to remove the out directory but of course it's not empty.
Well,
Remove out directory manually and try again from the beginning..
After step 5, Before you continue to next step try to remove the whole out directory manually again.
Try also to give your account full control to the converter's folder.
This problem seems to he a windows security permission issue. Are you an administrator on the system you use?
-------------------------------------------------------------------
Stock based ROMs need more files to be changed, but they are not included yet, because I don't have the whole info needed.
Hope @rugglez or someone else will be willing to help.
Till then avoid converting stock-based roms,( or after converting replace the boot.img in converted rom with a working boot.img from another stock-based rom for the same bootloader of course. This may work)
Try ONLY CM-based roms.
I forgot to write it in OP. I'll do it asap.
Click to expand...
Click to collapse
I have a list of files/folders which I was using to port...Thanks to @rugglez ofcourse...
If you have seen the dev section....I was porting a few ROMs from Old to New BL including the stock ROMs.
So, I will send you the list by PM.
I will try the CM based ones with manual clearing...and will check that
EDIT: I am the administrator...so normally only one account and I have that rights too
thanks once again
Okay, I just used the converter on Win8 x64 to create an oldbl version of my CM10.2 ROM.
I have uploaded the resulting zip here: http://tonyp.basketbuild.com/index.php?dir=main/CM-10.2/oldbl-untested-builds/
It is untested - so do a backup!
I will post the steps I took, this might help some people who never worked with tools like this.
Please try it out with different ROMs - and if the resulting zips work a) post that here and b) share the zip in the respective threads for others to use
If you have any erros post the complete cygwin output here.
To get it do a right-click into the cygwin window, then press Enter - it's now copied into the clipboard!
Okay, off we go:
Preparation (one time only):
Downloaded cygwin. and install it
The path C:/cygwin is perfecly fine.
Just press Next until you get to the paket selection, then use the searchbox to quickly get to the tools needed:
(just click once on it, the first checkbox will get checked. The second one is for the sourcecode, you don't need that).
- zip (Archive)
- unzip (Archive)
- cpio (Utils)
- perl: Larry Wall’s Practical (perl) (you might have to open "perl" and look for it manually)
- perl_vendor (perl)
Downlaod the zip attached at the OP, extract it.
I extracted it to C:/temp/ROM-Converter-tools/
done
ROM conversion:
Open the Cygwin Terminal (either in the start menu or execute the Cygwin.bat at C:/cygwin/)
Put the ROM zip into the source_zips folder
Type:
Code:
cd /cygdrive/c/temp/ROM-Converter-tools
Needs to get adapted to your path if you extracted the ROM-Converter-tools somewhere else.
My path is: C:/temp/ROM-Converter-tools/
(Hint: after /cygdrive/c/ autocompletion with TAB will work!)
I didn't try the drag&drop tip of spyrosk.
Type:
Code:
./convert2old_bl.sh
(or convert2new_bl of course if you're going the other direction)
Follow the instructions on the screen,
As it's still in the debug mode you need to press [enter] a couple times.
This will change in the future.
Done, your converted ROM will be in the out_oldbl or out_newbl folder.
do this tool work with CM7
tonyp said:
Okay, I just used the converter on Win8 x64 to create an oldbl version of my CM10.2 ROM.
I have uploaded the resulting zip here: http://tonyp.basketbuild.com/index.php?dir=main/CM-10.2/oldbl-untested-builds/
It is untested - so do a backup!
[/LIST]
Click to expand...
Click to collapse
uhm ... in my case it got stuck at CM booting logo ... is flashing it recovery sensitive?
spyrosk said:
"...I just converted Avatar-3.1 from old to new. No errors at all.
I don't like the write-protected error: rm: remove write-protected regular file `out/ramdisk/charger'
So it tries after that to remove the out directory but of course it's not empty.
Well,
Remove out directory manually and try again from the beginning..
After step 5, Before you continue to next step try to remove the whole out directory manually again..."
Click to expand...
Click to collapse
Hummmmm, I tried experimenting, and it happened to me the same as the partner "SREEPRAJAY"! ...
Here are the errors I had during the experiments (three files *. pdf);
Hrmph.
Was running the latest CM 10.1 nightly. Rooted, old bootloader, CWM Recovery 6.0.3.1.
Made a Nandroid backup. Wiped everything from recovery, factory reset, flashed this :
http://tonyp.basketbuild.com/download.php?file=main/CM-10.2/cm-10.2-20130821-UNOFFICIAL-p990.zip
According to CWM all flashed and well. I rebooted.
Phone's bricked, won't even boot to recovery, gets stuck in the LG logo. Ouch. Halp ?
Ultramanoid said:
Hrmph.
Was running the latest CM 10.1 nightly. Rooted, old bootloader, CWM Recovery 6.0.3.1...flashed this :
http://tonyp.basketbuild.com/download.php?file=main/CM-10.2/cm-10.2-20130821-UNOFFICIAL-p990.zip
Click to expand...
Click to collapse
But...that ROM is for NEW BootLoader!!!...
Use All-In-One Toolkit to reattach the situation (reinstall again CWM Recovery);
http://forum.xda-developers.com/showpost.php?p=34809475&postcount=1
trocopassu said:
But...that ROM is for NEW BootLoader!!!...
Use All-In-One Toolkit to reattach the situation (reinstall again CWM Recovery);
http://forum.xda-developers.com/showpost.php?p=34809475&postcount=1
Click to expand...
Click to collapse
I know ! ( NEVER flash anything as soon as you wake up without checking twice, kids. )
I saw the one for old bootloader for the 20th, moved up a directory, happily flashed the one for the 21th... and for the NEW bootloader.
Don't have access to a laptop to tinker and won't for a few days. Sigh.
millionsun93 said:
do this tool work with CM7
Click to expand...
Click to collapse
No, and it never will.
GB relies on the old bootloader. It would be a lot of work to make it compatible, which isn't worth the trouble at all.
flat__line said:
uhm ... in my case it got stuck at CM booting logo ... is flashing it recovery sensitive?
Click to expand...
Click to collapse
Ah that's a shame. spyrosk needs to have a look at that when he gets some free time.
You did a full wipe didn't you?
If you did it sound like an error in the fstab.
Ultramanoid said:
I know ! ( NEVER flash anything as soon as you wake up without checking twice, kids. )
I saw the one for old bootloader for the 20th, moved up a directory, happily flashed the one for the 21th... and for the NEW bootloader.
Don't have access to a laptop to tinker and won't for a few days. Sigh.
Click to expand...
Click to collapse
Your partitions are borked and you will have to use nvflash.
I'm sorry about that although I don't really know how you came to the idea to try the untested oldbl builds when you got no PC around to recover.
This could have even happened with the correct rom - again, it is completely untested.
Sent from my LG-P990 using Tapatalk 4
  
tonyp said:
Ah that's a shame. spyrosk needs to have a look at that when he gets some free time.
You did a full wipe didn't you?
If you did it sound like an error in the fstab.
Click to expand...
Click to collapse
I did the full wipe (I checked: I used the ext4 full wipe zip by dr4go for the old bootloader, as I usually do, using CWM 5.0.2.8)

[cm12.1] [cm13.0] [maybe touchwiz] Kali NetHunter for the Galaxy S5

WARNING: THIS IS A BETA, USB CABLES MAY CATCH FIRE, YOUR CHAIR MAY BREAK, AND TRUMP MAY WIN THE ELECTION!
Welcome to the thread on Kali NetHunter for the Galaxy S5.
These Kali NetHunter builds are designed for CyanogenMod 12.1 and CyanogenMod 13.0.
I have TouchWiz builds as well, but NetHunter has not been tested on TouchWiz.
In theory, they should work fine on all AOSP based ROMs. The TouchWiz might work on most custom TouchWiz 5.0 ROMs too!
I am releasing on a nightly based development schedule similar to CyanogenMod.
Occasionally builds can show up more than once per night. This usually happens when there's a big update like a new device added to the line or an apk update for the NetHunter app.
These builds are NOT Aroma enabled, however, it should be no issue to just drag apps you don't need to the uninstall button in your app drawer.
Aroma support is going to be phased out for a while, especially with new TWRP releases coming out soon that may have newer kernels that aren't compatible with Aroma.
DOWNLOAD
Current version: 3.0.1 (beta, 2016-01-21)
Please be careful to download the right version based on this table:
SM-G900F, SM-G900W8, SM-G900T, SM-G900M, SM-G900A, SM-G900S, SM-G900K: klte
SM-G900I: kltedv
SM-G900P: kltespr
SCL23 kltekdi
CyanogenMod 12.1: lollipop
CyanogenMod 13.0: marshmallow
Nightly TWRP flashable zips are located at: https://idlekernel.com/nethunter/nightly/
Kernel only installers are in the kernel-only directory inside each build directory. It might be a better idea to try and install that first and see if you can boot before flashing the entire NetHunter.
BEFORE INSTALLING
Do not flash the NetHunter update zip with a fresh data partition!
Most ROMs will wipe it clean on the first boot if you haven't completed the Android Setup Wizard yet, there's no need to wipe your ROM or data to try it out. I do advise backing up your data partition before flashing the zip though.
Please make sure your phone boots fine and runs fine before flashing NetHunter. It's confusing when people report bugs that exist in CyanogenMod by itself.
The Kali chroot and apps are installed on your data partition (in /data/local for chroot). To initialize the chroot and install Kali Linux, you need to start the Kali NetHunter app.
If you are already rooted or know you have systemless SuperSU installed, you will need to go into the SuperSU app and do a full unroot then reflash CyanogenMod (for the unmodified boot partition) and Gapps. The NetHunter installer does not play well with systemless SuperSU at this time.
The NetHunter installer will automatically install SuperSU in system mode, which I consider to be more stable. Since NetHunter already modifies your system partition, there is no need to use systemless SuperSU anyways.
FULL FRESH INSTALL STEPS
Flash CyanogenMod installer zip
Flash Gapps if you want them (preferably OpenGapps pico)
Boot into device
Complete setup wizard
Reboot into recovery
Flash the Kali NetHunter installer zip from this thread
Boot into device
Open the NetHunter app
Use the Kali Chroot Manager to install Kali on your phone
You're done!
UPDATING TO A NEWER BUILD
Going from 3.0.0 and up, all you have to do is flash the new build in recovery and wipe dalvik cache.
Upgrading from NetHunter 2.0 is not recommended, and may break the NetHunter app in some cases.
RAN INTO AN ISSUE OR BUG?
In order for me to help you, you have to at minimum reply with:
The link to the exact zip you downloaded
Your device model (klte, kltecan, kltesovietrussia, etc.)
The name of the ROM you're flashing it on
The version and build date of the ROM you're flashing it on
A complete description of your problem
Optional: An audio recording of you reading this entire post
If your issue is with a specific app, it might be better to contact the developer of that app.
If your issue is during the installation (ex. flashing the NetHunter zip), then please collect a TWRP recovery.log for me.
If you found a problem and were able to fix it, and no one's mentioned it in the thread already, it would be kind to state the issue and your fix for others to make use of as well.
You can join me and the other NetHunter developers on IRC at the #nethunter room on freenode to more handily diagnose problems together.
I apologize, but I can't do house calls at this time.
KNOWN ISSUES
F2FS - You need to have an ext4 data partition. I'm not sure why, but having a Kali chroot on your data partition totally breaks booting f2fs /data.
There is currently no fstab modifications in NetHunter, but I do plan on making a zip to automatically modify the fstab for f2fs later.
Marshmallow - New android app permissions API can wreak all sorts of havoc. On first boot, accept all permissions after opening the NetHunter app then reboot your phone. You might need to battery pull if it freezes up completely. Once app permissions are accepted, the next reboot should hopefully not freeze up and allow you to install your chroot normally. (once the NetHunter app has full support for the new Android API this should no longer be an issue)
USB Keyboard - The keyboard is unusable on some devices (ex. the Note 3) due to a depth bug that causes your key presses to go right through the keyboard into the swipe pad.
Terminal App - Full screen programs like nano or vi are unusable because they can't be rendered properly. Learn sed for text file editing. Just kidding that's cruel.
Install OpenSSH server in Kali and use the JuiceSSH app as an alternative to NetHunter Terminal. (it's wayyyy better sorry jmingov)
THE KERNEL
The NetHunter kernel for the Galaxy S5 is based on CyanogenMod 13.0 kernel sources.
It has the following changes:
F2FS updated to Jaeguek Kim's latest kernel.org f2fs-stable sources
UKSM Ultra Kernel Same-page Merging KSM support
Updated and enabled USB (OTG) Atheros, Ralink, and Realtek WiFi drivers
Krait specific Cortex-A15 & Neon-VFPv4 + -O2 compiler optimizations
Compiled with Linaro's branch of GCC 4.9.4
Simple IO (SIO) scheduler as default IO scheduler
USB HID Gadget keyboard support
mac80211 packet injection support
Additional drivers built in for the full Kali NetHunter experience
SCREENSHOTS
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
DEVELOPMENT
For the kernel included in NetHunter for the Galaxy S5, you can find the sources here: https://github.com/jcadduono/nethunter_kernel_klte
You can see my branch of the installer development here: https://github.com/jcadduono/kali-nethunter
Alternatively, but not updated as often, it is also available as another branch on the Offensive Security NetHunter GitHub: https://github.com/offensive-security/kali-nethunter/tree/master-jcadduono
The original branch of development is located here: https://github.com/offensive-security/kali-nethunter
DISCLAIMER
I am not affiliated with Offensive Security. They seem like cool guys though.
I'm not even a novice when it comes to security and penetration. I'm just a simple system administrator with a passion for breaking Android.
Please restrain yourselves from asking me security related questions.
Reserved
NOT SO MUCH AS SEEN ON MR. ROBOT, BUT PROBABLY EVEN BETTER
Hey Jcadduono, just wanted to say thanks! i was trying to do the same thing but never had enough time to fix all kernel recompile issues i got.
I am going to install this and run it as my daily driver i will let you know if i come up with any issues.
Thanks again and keep up the good work! If you need help anytime just say i am willing to help anytime anyway i can.
What about touchwiz
sielhadi said:
What about touchwiz
Click to expand...
Click to collapse
It's possible I could create a touchwiz branch (forked from my CM13 branch), but it would be unofficial and probably less maintained.
It would have a bunch of hacks to force the kernel to always be permissive to get past some issues, as well as merged latest drivers from touchwiz.
I would like to see if this CyanogenMod kernel works first though.
mixa2038 said:
Hey Jcadduono, just wanted to say thanks! i was trying to do the same thing but never had enough time to fix all kernel recompile issues i got.
I am going to install this and run it as my daily driver i will let you know if i come up with any issues.
Thanks again and keep up the good work! If you need help anytime just say i am willing to help anytime anyway i can.
Click to expand...
Click to collapse
Feel free to clone my nethunter_kernel_klte git branch, it's fully compliant with GCC 4.9.X. If you need any specific features you can send pull requests and it might merge them into main.
You should have no problems building it with build.sh or build_nethunter_images.sh (just edit the path variables in config sections of each file to point to right directory and compiler)
To build for kltecan, for example, just type
Code:
./build.sh can
You will get a zImage and a dtb.img inside ./build/arch/arm/boot folder.
Flashing kernels takes a little bit more work. You have to clone my kali-nethunter branch. Copy the zImage and dtb.img (replace the current ones) in ./nethunter-installer/kernels/androidversion/klteX/.
Then all you have to do is go to the ./nethunter-installer folder and do
Code:
./build.py -d klteX --androidversion -k
The -k flag builds just a kernel flashing zip out of your new zImage and dtb.img. Replace androidversion with marshmallow or lollipop. Replace X with your klte variant, ex. kltecan.
You can then flash that zip in TWRP and it will install your new kernel.
jcadduono said:
It's possible I could create a touchwiz branch (forked from my CM13 branch), but it would be unofficial and probably less maintained.
It would have a bunch of hacks to force the kernel to always be permissive to get past some issues, as well as merged latest drivers from touchwiz.
I would like to see if this CyanogenMod kernel works first though.
Feel free to clone my nethunter_kernel_klte git branch, it's fully compliant with GCC 4.9.X. If you need any specific features you can send pull requests and it might merge them into main.
You should have no problems building it with build.sh or build_nethunter_images.sh (just edit the path variables in config sections of each file to point to right directory and compiler)
To build for kltecan, for example, just type
Code:
./build.sh can
You will get a zImage and a dtb.img inside ./build/arch/arm/boot folder.
Flashing kernels takes a little bit more work. You have to clone my kali-nethunter branch. Copy the zImage and dtb.img (replace the current ones) in ./nethunter-installer/kernels/androidversion/klteX/.
Then all you have to do is go to the ./nethunter-installer folder and do
Code:
./build.py -d klteX --androidversion -k
The -k flag builds just a kernel flashing out of your new zImage and dtb.img. Replace androidversion with marshmallow or lollipop. Replace X with your klte variant, ex. kltecan.
You can then flash that zip in TWRP and it will install your new kernel.
Click to expand...
Click to collapse
You are AWESOME!
Thank you very much. I will try this as soon as i have time.
Got a bootloop on cm12 29.12.15 version. Clean install, no gapps, fully setup before flashing kali zip. Note that the device stays in the starting screen for like half a minute and goes to bootscreen then which it usually doesnt
dr460nf1r3 said:
Got a bootloop on cm12 29.12.15 version. Clean install, no gapps, fully setup before flashing kali zip. Note that the device stays in the starting screen for like half a minute and goes to bootscreen then which it usually doesnt
Click to expand...
Click to collapse
Do you get the same result with kernel-only zip? (if you flashed full zip, you will have to restore system, data, boot backups before trying kernel only)
Sorry for being a bit ignorant, but can someone explain me what is NetHunter? I've seen it for some devices but still have no idea what is it & what does it do...
I cannot, for the life of my get the 19-19 build to boot up, should I try another nightly? I'm flashing the full zip file ontop of a booted cm 13 + gapps install.
---------- Post added at 11:30 PM ---------- Previous post was at 11:29 PM ----------
Sorry should of added this, I'm on kltespr, and am flashing the 2nd one that came out.
pro_granade said:
I cannot, for the life of my get the 19-19 build to boot up, should I try another nightly? I'm flashing the full zip file ontop of a booted cm 13 + gapps install.
---------- Post added at 11:30 PM ---------- Previous post was at 11:29 PM ----------
Sorry should of added this, I'm on kltespr, and am flashing the 2nd one that came out.
Click to expand...
Click to collapse
sorry I need feedback from people who are just installing the kernel zip right now. I need to pinpoint whether the issue is kernel related or NetHunter script related.
for folks trying the kernel-only zips: Are you stuck on a neverending Kali boot logo, or the black screen with set warranty bit?
jcadduono said:
first
NOT SO MUCH AS SEEN ON MR. ROBOT, BUT PROBABLY EVEN BETTER
Click to expand...
Click to collapse
i am downloading right now this alone convices me
jcadduono said:
sorry I need feedback from people who are just installing the kernel zip right now. I need to pinpoint whether the issue is kernel related or NetHunter script related.
for folks trying the kernel-only zips: Are you stuck on a neverending Kali boot logo, or the black screen with set warranty bit?
Click to expand...
Click to collapse
bootloop
pro_granade said:
bootloop
Click to expand...
Click to collapse
doesn't help, boot loop is not specific
ALSO I really want recovery.log from TWRP with it!! (from when you flashed it)
Stuck at samsung screen
malbert16442 said:
Edit:will update with info starting fresh again
Click to expand...
Click to collapse
I might have found the issue. I was recompressing the ramdisk to the format it came in, rather than recompressing to gzip which is what the NetHunter kernels are set to use. I'm not sure what format CyanogenMod's klte ramdisks come in, but if it was anything other than gzip or xz then it wouldn't boot.
3.0.1-20160119-1913 forces ramdisks to gzip -9 instead. Hopefully that one will fix it. I suggest restoring original boot.img before flashing.
Edit: Your log says the compression was gzip, so I have no clue why it wouldn't boot. Gonna need more infos.
Also your log shows that there was no wallpaper in /data, do you have an empty data partition? It won't boot properly if android is not set up.
Update: 3.0.1-20160119-1944 will check to see if it's okay to install before trying to install.
jcadduono said:
I might have found the issue. I was recompressing the ramdisk to the format it came in, rather than recompressing to gzip which is what the NetHunter kernels are set to use. I'm not sure what format CyanogenMod's klte ramdisks come in, but if it was anything other than gzip or xz then it wouldn't boot.
3.0.1-20160119-1913 forces ramdisks to gzip -9 instead. Hopefully that one will fix it. I suggest restoring original boot.img before flashing.
Edit: Your log says the compression was gzip, so I have no clue why it wouldn't boot. Gonna need more infos.
Also your log shows that there was no wallpaper in /data, do you have an empty data partition? It won't boot properly if android is not set up.
Update: 3.0.1-20160119-1944 will check to see if it's okay to install before trying to install.
Click to expand...
Click to collapse
So this new update should be okay to flash?
pro_granade said:
So this new update should be okay to flash?
Click to expand...
Click to collapse
probably not, I still need someone to get me some form of logs while booting with kernel-only zip. I can't think of anything at all that could be preventing boot. it's even more confusing that you guys aren't even hitting the cyanogenmod boot splash.
jcadduono said:
probably not, I still need someone to get me some form of logs while booting with kernel-only zip. I can't think of anything at all that could be preventing boot. it's even more confusing that you guys aren't even hitting the cyanogenmod boot splash.
Click to expand...
Click to collapse
I dont know why log didn't show it but it did display an error about unpacking boot image. I had data and apps installed.
Are you going to compile from your source again or you want to find a definite answer.
P.s same issue with 12.1 and 13.0 with kernel.
Sent from my Samsung Galaxy S5 using Tapatalk
I think I might have fixed the issue. SELinux related. Will have new builds up soon.
Update:
https://idlekernel.com/nethunter/nightly/3.0.1-20160121-0200/
are these working for you guys?

Samsung Galaxy Tab A 7.0 LTE (2016) SM-T285 Lineage OS complete build guide

For SM-T285 users that want to build Lineage OS for their own device I have posted a complete build guide here:
https://github.com/lineage-gtexslte/build_guide
jedld said:
For SM-T285 users that want to build Lineage OS for their own device I have posted a complete build guide here:
https://github.com/lineage-gtexslte/build_guide
Click to expand...
Click to collapse
Thanks for the ROM update!
I started from scratch and when I compiled, I got this error:
fixdep: error opening config file: ../../../../../../kernel/samsung/gtexslte/scripts/genksyms/parse.tab.c: No such file or directory
I have had this error before and had to copy the file from another folder, but I should not have to do this.
So, I copied the file to folder where it was missing.
New error:
target Prebuilt: am (/home/gcrutchr/taba/out/target/product/gtexslte/obj/EXECUTABLES/am_intermediates/am)
Symlink: /home/gcrutchr/taba/out/target/product/gtexslte/system/bin/app_process -> app_process32
clang++: error: unable to execute command: Aborted (core dumped)
clang++: error: linker command failed due to signal (use -v to see invocation)
gcrutchr said:
Thanks for the ROM update!
I started from scratch and when I compiled, I got this error:
fixdep: error opening config file: ../../../../../../kernel/samsung/gtexslte/scripts/genksyms/parse.tab.c: No such file or directory
I have had this error before and had to copy the file from another folder, but I should not have to do this.
So, I copied the file to folder where it was missing.
New error:
target Prebuilt: am (/home/gcrutchr/taba/out/target/product/gtexslte/obj/EXECUTABLES/am_intermediates/am)
Symlink: /home/gcrutchr/taba/out/target/product/gtexslte/system/bin/app_process -> app_process32
clang++: error: unable to execute command: Aborted (core dumped)
clang++: error: linker command failed due to signal (use -v to see invocation)
Click to expand...
Click to collapse
What's your gcc version? might need to use gcc 6
jedld said:
What's your gcc version? might need to use gcc 6
Click to expand...
Click to collapse
gcc version 8.1.1 20180712 (Red Hat 8.1.1-5) (GCC)
gcrutchr said:
gcc version 8.1.1 20180712 (Red Hat 8.1.1-5) (GCC)
Click to expand...
Click to collapse
later versions of gcc may not work with lineage 14.1, I had to downgrade mine, though for another project.
you can do:
Code:
sudo apt-get install gcc-6 g++-6 g++-6-multilib
sudo update-alternatives --install
inform me if this works and I'll update my guide. Might consider making a docker based build if issues like this happen often.
jedld said:
later versions of gcc may not work with lineage 14.1, I had to downgrade mine, though for another project.
you can do:
Code:
sudo apt-get install gcc-6 g++-6 g++-6-multilib
sudo update-alternatives --install
inform me if this works and I'll update my guide. Might consider making a docker based build if issues like this happen often.
Click to expand...
Click to collapse
Actually, I am on Fedora Linux (uses less resources) and have been using gcc 8xx for some time. I compile LineageOS 14.1 for Note 3 (ha3g) and the Note Pro 12.3 (v1a3g) and have no problems. But, I will investigate further.
Ok...so I had issues building the kernel...could not find some include files.
So...I decided to use build_kernel.sh script to to make boot.img. The resultant file is about 1.4 MB smaller, there is no init file in the ramdisk folder and the boot.img-ramdisk.cpio.gz in the split_img folder is about 1/2 the size of your recent boot.img file.
Not sure when to go from here.
Okay, so I followed the instructions - after upgrading Fedora to v29 - but, this time I used Docker. Had to make some script changes for Fedora, but got most everything installed. The "work" directory is empty. I was able to make a working system.img that installed with the built .zip file. The kernel would not boot - hung on the logo screen. I restored the 10/17 boot.img and the system booted up. Now, I will work on the boot.img file. I did notice this time that the boot.img file was about the same size as the 10/17 boot.img file I downloaded. So, that's an improvement. I just finished modifying the build_kernel.sh file. So, I installed the kernel I made and it still hung on the logo screen. So, back to square 1 regarding the kernel.
gcrutchr said:
Okay, so I followed the instructions - after upgrading Fedora to v29 - but, this time I used Docker. Had to make some script changes for Fedora, but got most everything installed. The "work" directory is empty. I was able to make a working system.img that installed with the built .zip file. The kernel would not boot - hung on the logo screen. I restored the 10/17 boot.img and the system booted up. Now, I will work on the boot.img file. I did notice this time that the boot.img file was about the same size as the 10/17 boot.img file I downloaded. So, that's an improvement. I just finished modifying the build_kernel.sh file. So, I installed the kernel I made and it still hung on the logo screen. So, back to square 1 regarding the kernel.
Click to expand...
Click to collapse
Were you able to obtain a logcat with the failed boot? Possible issue is that the external kernel modules did not get compiled
jedld said:
Were you able to obtain a logcat with the failed boot? Possible issue is that the external kernel modules did not get compiled
Click to expand...
Click to collapse
Actually, not sure how I got it to compile. Having problems with docker. Cannot run python or any other dev command. Stuck as root user. So am trying to learn about docker. I do not think I was in docker when it compiled. Will get back to you after I figure this whole mess out.
27 October 2018
After reading the Docker documentation and playing with Docker, I removed it from Fedora. It is just too complicated to use even though it sounds simple. After removing Docker, I did a make clean and a make mrproper in the kernel folder. I ran 'brunch gtexslte'. The compile completed after I copied mkbootimg to the out folder - for some reason it is not getting copied there during the make process. This time the boot.img was over 9mb. It still will not boot. I will get log files today. I will also check to make sure the system files work with the good boot.img.
Question how do I update the system folder to the latest builds of lineage 14.1?
Your repo xml file restricts the source to your repo.
Okay!
Fixed boot.img not booting.
If you unpack boot.img, the file 'boot.img-imgtype' has an invalid image type. In the file, it says 'AOSP-PXA'.
It should say 'AOSP'.
I do not know where this is getting added. I have done a grep and could not find it.
As a side note, I used the build_kernel.sh script to make the kernel.
Question: How do I apply the security updates without manually following the (-) (+) in the diff file?
I am now able to do a complete make and install using the generated .zip file.
Here are the steps:
1. Setup your environment - I am using Fedora, but these instructions will work for any flavor of linux
2. Make sure you have the linaro gcc toolchain (32-bit) installed, and you have modified kernel/samsung/gtexslte/build_kernel.sh
3. Run: build/envsetup.sh, then brunch gtexslte
4. If the brunch stops near the end, copy mkbootimg from system/core/mkbootimg to out/host/linux-x86/bin
......or you can write a shell script to copy the file, as I did, before starting the build
5. After the build completes, cd into kernel/samsung/gtexslte
6. Run make mrproper, to clean the kernel folders
7. Run build_kernel.sh
8. After the kernel (zImage) is built, you need to make the boot.img
9. @jedld has posted how to do this in his build instructions
10. Now that you have a boot.img, you need to modify it.
11. Unpack boot.img
12. In the file 'boot.img-imgtype' , you need to change 'AOSP-PXA' to 'AOSP' - without the quotes
13. Repack boot.img
14. Replace boot.img in the lineage*.zip file with the one you just modified
15. Copy the lineage*.zip to you Tab-A, reboot into recovery and install it.
Here is my script for copying the mkbootimg file into the out folder, BEFORE I run brunch gtexslte:
if [ ! -d "out/host" ]; then
mkdir out/host
mkdir out/host/linux-x86
mkdir out/host/linux-x86/bin
fi
cp system/core/mkbootimg/mkbootimg out/host/linux-x86/bin
@jedld
Update on normal kernel build:
The reason the boot.img - when building via brunch gtexslte - will not boot is a bad zImage. If I replace the zImage from a bootable boot.img, the bad boot.img will boot okay.
Now I need to figure out what the problem is.
you can get the incremental diffs from linux.org
jedld said:
you can get the incremental diffs from linux.org
Click to expand...
Click to collapse
Is this for kernel changes or security patches?
gcrutchr said:
Is this for kernel changes or security patches?
Click to expand...
Click to collapse
My mistake, I meant kernel.org not linux.org. The incremental diffs contain changes to the mainline kernel which can contain security fixes and/or bug fixes. This is different from android specific patches which google releases separately as kernel patches. The kernel started out from the stock sources provided by samsung on 5.1.1 and then I added google's N and Oreo patches on it (patches related to selinux and oreo binder enhancements). I also added incremental diffs from kernel.org, it started out at 3.10.58 and then I applied incremental diffs until I got to 3.10.107. Unfortunately 3.10 is EOL now, upgrading the kernel to the 4.10 series will take a lot of work.
The SM-T285 Lineage OS is excellent. Is it possible to get the FM radio working? I have tried everything but can't get it to work. I would appreciate your help.
akasarf said:
The SM-T285 Lineage OS is excellent. Is it possible to get the FM radio working? I have tried everything but can't get it to work. I would appreciate your help.
Click to expand...
Click to collapse
It's probably not implemented in the kernel.
Just downloaded Radio FM from PlayStore and installed it. It works!!
I meant if there is a working FM radio tuner app that works without the internet on Lineage
gcrutchr said:
It's probably not implemented in the kernel.
Just downloaded Radio FM from PlayStore and installed it. It works!!
Click to expand...
Click to collapse

Categories

Resources