yashsingh1/xdaforums huggingface dataset:
[XDA-University] jusho:
Sir here is my updater script + binary. I already solved error execute updater script. Its because assert boot.img wrong mount. Now i already succeed flash but stuck in boot screen. The 1st boot screen before samsung glowing splash screen. I try only create working folder in kitchen and directly make zip. So i guest no mod i apply for this zip. But why its stuck, can you help me sir?

Here i attach updater script, updater binary and recovery.fstab.

Tx before
[XDA-University] shoey63:
Most informative guide :cool:
[XDA-University] jusho:
Its Done sir, tx a lot;) i already make my first custom rom but without kernel
[XDA-University] demkantor:
Sorry forgot to look at your script, so is everything working as it should?
[XDA-University] jusho:
Its work now except i dont include the boot.img file and remove the line from updater script. Its like when i include the boot.img its always stuck in smasung gt9152 screen, i thought it wont boot. Is it kernel problem? i use stock kernel. How to know the real mounting of kernel sir?
[XDA-University] demkantor:
the best way to test kernels is with fastboot, its clean, its quick its simple, unfortunately many phones dont have this option and yours being a samsung i doubt it does as few samsungs do.

so lets make a quick flashable.zip to test, get your phone up and running and get a folder ready

looks like you have the kernel as .img, this is good, its easy to work with, and accordint to fstab its located in /dev/block/mmcblk0p5

so in new folder put boot.img, and another folder called META-INF / com / google / android / now put updater-script and update- binary here(follow the earlier guide for this)

now for udater-script just write a simple script, looks something like

ui_print("Installing Kernel...");
package_extract_file("boot.img", "/dev/block/mmcblk0p5");
ui_print("Kernel install finished, hope it works!,");

now zip, sign and flash

if it gets stuck you know your script worked but the kernel is bad

if it boots and about phone shows new kernel then awesome!

if it boots but nothing has changed than there is an issue with script

let me know how this all works!
[XDA-University] jusho:
Wooow its work man:good::laugh:

If this stand alone flashable kernel is working but why the boot that cooke by kitchen doesnt work. Its the same updater-script, the same boot.img.
[XDA-University] shoey63:
Could be wrong update binary. Tell your Cooke to download a cm ROM for your device and extract and replace update binary in his zips.
[XDA-University] jusho:
The problem is there is no CM version yet for my device. I've idea to make a rom bithout kernel first (deodexed) then i update the zip with boot.img and update the script for the boot.img. Is it possible?
[XDA-University] demkantor:
Its hard to say for sure why your other script won't flash the kernel, it looks right. Can you get a recovery log right after the flash so I can see where the error is?
[XDA-University] shadman0:
Thanks You

Shadman0 If I help U Pls Give Thanks

My Work http://xdaforums.com/showthread.php?t=2521867
[XDA-University] lispsne:
thanks for sharing!:good::good::good::good::good::good::good::good:
[XDA-University] yashade2001:
Hey [MENTION=4334383]demkantor[/MENTION] I'm making an IDE for Edify. What do you think ? I'm making that for syntax highlighting and making zips easier etc...
[XDA-University] demkantor:
[MENTION=4872224]yashade2001[/MENTION]

Sounds like a great idea! There have been a few made in the past but as far as I know are not currently being developed. Also the often needed users to use the command line so it wasnt much easier. So if you make a well working one with an intuitive ui I think it would be awesome! Maybe talk with some of the people who started making these and see if you can pick up their work where they left off, best of luck!
[XDA-University] yashade2001:
I started to make the edify editor in c#, you know autocomplete, syntax highlight etc...
[XDA-University] dm5530:
Your suggestion for a signing tool for Windows takes me to a page that asks for a password. Is there another download location you might suggest or another tool?

Thanks.
[XDA-University] demkantor:
Try the one right below that one, seems to work from my tablet just fine. I'll make some new uploads for this, thanks for bringing it up

And that reminds me I still have to finish this thread!
[XDA-University] phantomhell:
nice guide
[XDA-University] hackerontes:
Thanks for sharing this guide...

Hi to everybody on this thread and thanks, thanks a lot, for this useful guide...

Only a question: i'm triyng to download SignApk.rar from your link (mediafire) but it seems that is still not working...

There are other ways to get it...? maybe googling SignApk.rar...?

I've succesfully downloaded the other tool (the rightclick one) but for completeness reasons i'd like to collect & try all the tools suggested.

Thanks again and excuse my bad english (i'm italian)

regards, hackerontes

P.S.

Ehi! I've found on 4Shared an archive named SignApk.rar checked with Avast1 & says it's SAFE.

IT contains:

comando.txt ( java -jar signapk.jar certificate.pem key.pk8 your-app.apk your-signed-app.apk

signapk.jar certificate.pem key.pk8 your-app.apk your-signed-app.apk )

signapk.jar

README

certificate.pem

key.pk8

thanks in advance for explanations suggestions etc.

cheers & regards, hackerontes
[XDA-University] s3icc0:
Hi

Can you tell me what is the difference between:

mount("ext4", "EMMC", "/dev/block/mmcblk0p3", "/system");

and

run_program("/sbin/busybox", "mount", "/system");

and what and how should I use to be able to copy files to

/res/customconfig/

- how can I determine partition/mount point - I am still bit a lost in this so I don't know how to design my updater-script...

this is what I have now - but I am not sure it will be working - or it will not damage the phone:

run_program("/sbin/busybox", "mount", "/res");
delete("/res/customconfig/customconfig-helper", "/res/customconfig/customconfig.xml", "/res/customconfig/actions/push-actions/config_backup_restore");
package_extract_dir("res", "/res");
set_perm(0, 0, 6755, "/res/customconfig/customconfig-helper", "/res/customconfig/customconfig.xml", "/res/customconfig/custom.profile", "/res/customconfig/actions/push-actions/config_backup_restore");
run_program("/sbin/busybox", "unmount", "/res");

thank you for any help (the script should help me to create some custom features for the kernel I use which is operated by STweaks app)
[XDA-University] demkantor:
They effectively do the same thing, the first you need to know your mount points and your update-binary reads this to mount /system. The second does the same, but there you don't need to know mount points as it looks to your device.

To determine mount points there are a few ways, often opening an adb shell or terminal emulator and simply typing

mount

Will get you the info you need, or

cat /proc/mounts

If you can't find what you need let me know as there are many other ways as well (in some ways device specific)

I don't know of a partition called /res so I doubt this is what you should be looking for (maybe /system/res ?) So to understand better can you explain more? Did you edit some xml file and now you want a way to replace it? Or was the /res file part of an .apk or where did you find this file? And how did you edit it? What exactly will it do if replaced?

Oh side note, try not to post your question in multiple threads, xda frowns upon this
[XDA-University] s3icc0:
Thanks for answer. Sorry for multiple posts but there are multiple threads solving same issues so I was trying to raise the chances for success.

So basically the second method is better ... and maybe safer as i dont need to know exactly the partition name.

Usually all guides say "dont do anything to update-binary file, just take this one we are providing" so I opened several flashable packages and the files are not the same (now with my package i am having status 6 error and it is not getting to my updater-script so it must be connected to the binary)

The /res: when i look to my root folder there is a location called /res where i am trying to push my files to (there are some kernel settings related files). But i need to know on which partition the folder is to be able to mount the right one.

I am really stuck here .. I have great idea but no means to apply it :(
[XDA-University] demkantor:
That's fine, future reference just stick with one post

The update-binary for the most part is device specific, take a recent ROM for your device and unzip it and use this update-binary

That should solve your status 6 error

As for the red location I assume its in /system/res but without more info I can't say for sure, can you give me a screenshot or a guide you followed or just something more on where you found the file you edited
[XDA-University] s3icc0:
I tried update-binary from the kernel package I use and from the ROM I use .. both giving status 6 error: line 1 column 79 (from log in cwm), kernel binary is giving me also some note about updating binary - i don't really understand this

I also tried not to use notepad and prepare the files in notepad++ to get rid of the status 6, but still have it

the root structure is following (expanded is only the /res location for the purpose):

/acct
/cache
/config
/cpufreq
/cpugov
/d
/data
/dev
/efs
/etc
/external_sd
/extSdCard
/firmware
/lib
/mnt
/persist
/proc
/res (there is a kernel appSTweaks.apk, and some kerel scripts uci.sh, uci_for_loop.sh, user_uci_test_run.sh
---/customconfig (here are some xml and profile files)
------/actions (here are some voltage tables, frequency tables, hotplugging tables etc...)
---------/push-actions (here are some other kernel related fles)
---/images
---/no-push-on-boot
/root
/sbin
/sdcard
/storage
/sys
/system
/tmp
/tombstones
/usbdisk
/vendor
[XDA-University] demkantor:
I got ya now,

So the /res folder is for resources that certain apps or whatever uses, I'm not sure if you should change or even need to change something here rather you find the .apk in question and decompile this and change its resources. I may be wrong on this but to my understanding this isn't the place to make your changes

I'll do some Google searching when I get near a PC, maybe later tonight, to confirm. But for now maybe check out developer.android.com and search for "resources" there, I'm sure all import info will be there.

As for updater-script, feel free to upload this and I can fix whatever issue is there. But without seeing it all I can say is there is a problem on line 78, probably missing a ; but again can't say for sure without seeing it
[XDA-University] s3icc0:
Well thanks for tip i will definitely check the web.

I already manually did the change of the files and it is working great, but i need the flash package to automate this process :)

Actually the updater script has only cca 40 lines, i already checked it but did not find the issue.

Here is the link for whole package i did https://www.dropbox.com/s/ztc0cbz9wft4z6q/customprofile0003.zip

Anyway i dont want you to fix it i would love to do myself :)
[XDA-University] demkantor:
Sorry, again on mobile its easy to misread. The error said line 1 column 79 so my bad, so first line is bad, do two things, in notepad ++ go to edit,eol and choose Unix (maybe eol conversion its been a while) I'm guessing this is your issue

But also scan to make sure every line ends in )"

(Unless its a if then, thens won't)

When I get home I'll look at your updater-script and see what I can find, but for now check your end of lines
[XDA-University] s3icc0:
Hi, have you had a chance to look at my package? Thanks
[XDA-University] demkantor:
sorry, been busy and totally forgot about this

so looking at it for sure has some windows end of lines.

so open notepad++

highlight all lines in updater script

click edit

eol conversion

choose unix

now you will see all the CRLF blocks at the end turn into just LF

probably dont even need to mount /system to do this but wont hurt leaving it in the script

let me know if it all works as planned!
[XDA-University] s3icc0:
This function does not help me at all ... but after like twenty checks I found one missin ";" character :) ... meanwhile they changed my kernel so I have to rework it but then I will give a try
[XDA-University] demkantor:
Your eyes are better than mind, didn't see any missing ; at least not in the script I grabbed from your dropbox.

Go to view

Show symbol

Show all characters

Then toggle back and forth in the Unix/window eol and you'll see how those end of lines change, just be sure to be in Unix format and from what I see script should be good to flash

Either way best of luck, let me know if you get stuck!
[XDA-University] s3icc0:
Still no success after all :( I tripple checked everything, fixed one missing line end, but same error comming over and over. I am suspicios that it will be connected to the location where I am trying to push my files.
[XDA-University] demkantor:
Can you upload your new one, I suspect there is still an error in formating, the status 6 error won't have anything to do with flashing to /res
[XDA-University] s3icc0:
# ---- Mount /system ----
mount("ext4", "EMMC", "/dev/block/platform/msm_sdcc.1/by-name/system", "/system");
# ---- Flash the profile ----
# ---- Remove original files from /res ----
delete("/res/customconfig/customconfig-helper", "/res/customconfig/customconfig.xml", "/res/misc_scripts/config_backup_restore");
# ---- Copy new files to /res ----
package_extract_dir("res", "/res");
# ---- Set permissions to new files in /res ----
set_perm(0, 0, 6755, "/res/customconfig/customconfig-helper", "/res/customconfig/customconfig.xml", "/res/customconfig/custom.profile", "/res/misc_scripts/config_backup_restore");
# ---- Unmount /system ----
ui_print("Unmounting /system");
unmount("/system");
[XDA-University] demkantor:
I mean the whole file again
[XDA-University] s3icc0:
Thanks, but it wont be required .... I removed all the loading bars, ui_print("") and unnecessary stuff and it is working now :)

Appreciated your help!!!

EDIT: OR ....

script is working, but nothing is copied where I need it :D

Question: What will happen if I will just simply mount all partitions??? To be sure I am able to push my files where required.
[XDA-University] demkantor:
Well your pushing files to /res so there shouldn't be a need to mount any of other partitions. Can you get the recovery log after the flash? Most recoveries will have this in advanced settings
[XDA-University] s3icc0:
I just get the answer from dev ... The contents of this folder is recreated each time i boot the phone .. So no matter what i push inside it will be replaced soon ....

Anyway thanks for your effort.

I go learn understanding android bit deeper :)
[XDA-University] Le Ch@land:
Hi,

Great Tutorial. :good:

Does anybody know an instruction to delete only sub-folders Inside a folder and keep files Inside the root of it.

I want to delete only all the subfolders inside the folder /example.

And i want keep somes files which are in the root of this folder (they may be differents for each phone).

If i understand, this instruction delete all in the folder, inclued the folder itself:

delete_recursive("/system/example");

Is there an alternative which can do what i am searching for.

Thanks in advance. :cool:
[XDA-University] demkantor:
Not really, but you can delete specific files or delete a whole folder

delete_recursive("/system/keep/some/deletethis")

delete("/system/keep/file.xml")

This would delete all files in /system/keep/some

And then only delete /system/keep/file.xml

So you can specify a few items to delete, but if you want to delete all but one or to maybe run a busybox command to copy the 1 or 2 files into temp, delete all then copy files back
[XDA-University] gjpalathingal:
Very very hard helpful. Thanks
[XDA-University] gopzzz:
Hi Great Guide

Than you for the guide to make Aroma package.

How to enable aroma to install apps in priv-app folder in kitkat. I am using S3 4.4.2 rom made by Archidroid.

I was flashing my previous aroma mod package but now not able to do so.... I normally use aroma package creator app...

Many of them say,"need to update update - binary"... is it so...

please do guide me in creating a mod zip using aroma.

step by step guide would be great...

Thank you
[XDA-University] Alc@traZ:
so easy

thanks
[XDA-University] baseboy11`:
very simple

Great tutorial. Thanks bro. Large beer for you
[XDA-University] Irwenzhao:
Hello...

I'm writing a script to repartition a Note 1 (N7000) and I currently have two issues/questions:

Getting the partition information from terminal emulator (parted) shows me that the system partition's name is FACTORYFS, but when I install the app Partition Table, it shows me the system partition is mounted as /system. When I unmount the partition, do I do this

umount -l /system

or

umount -l /factoryfs

?

Next, how do I format a partition to FAT32?

Thanks in advance! Great guide!
[XDA-University] demkantor:
Hi,

I haven't ever used an app to create an aroma package so I wont be able to help guide you with one of those, but maybe you can link me to the ROM you are using and give some more details on what exactly you are going to do.

The update-binary for a ROM becomes the update-binary-installer once changed into an aroma package, if you are starting from scratch (as in you are taking a ROM and then turning everything into your personal aroma-package) the first thing you do is

download both ROM and Aroma installer (currently 2.7 or so)

now extract both .zips, (i use 7zip but use whatever)

take the META-INF folder from Aroma and replace it with one in ROM (but safe the one from ROM, you need it still)

now take the update-binary from ROM and rename it update-binary-installer and replace with one in new rom/aroma

now take the updater-script and open it up (if on windows use notepad++ on linux use gedit - others work fine too...)

actually, this may become a very long post if i go step by step, are there some specifics you need help with?

installing apps to a specific location is just a matter of telling them where to go in updater-script which user can select by adding options to aroma-config

I know i need to add more about aroma in this tutorial but for now if you give me specific question i'll be glad to guide you along

best of luck!

IF you mount /system then you unmount /system, I'm not 100% what you a re asking but it will depend specifically on how you run your mount command.

so an example would be

mount("ext4", "EMMC", "/dev/block/mmcblk0p25", "/system");
unmount("/system");

or

run_program("/sbin/busybox", "mount", "/system");
run_program("/sbin/busybox", "umount", "/system");

If you need more help on this feel free to ask

as for formatting a partition to fat32, I've never done this in android with an updater-script so I will just give you what would make sense to me,

format("fat32", "EMMC", "/dev/block/mmcblk0p25", 0);

but there are different ways to do this and of course you would need to change command to specific partition for your case, but I'm not sure of any partition that would be formatted to fat32 other than your primary sd card but you couldn't use a flashable.zip to format this.

maybe a bit more detail and i can help further

best of luck!
[XDA-University] Irwenzhao:
It's alright, got it figured out. I used mkfs -t FAT32 /dev/block/mmcblk

N7105 rocking AOSB with AGNi kernel,

Click "Thanks" if I was of any help!
[XDA-University] dankoman:
If anyone cares to learn from my hours of troubleshooting, never end a ui_print string with the character "\"

Causes following line to fail.
[XDA-University] Hnk1:
[MENTION=4334383]demkantor[/MENTION]

Cheers for your help!

Well you can say I am LOST in updater script.

I only want to format system and then flash boot.img and system folders in the rom. That's all!

I am uploading my updater script which has been copied from another rom. So it must be alot different.

I seem to flash fine but then nothing happens, so i basically end up with bootloop phone due to system being formatted and then nothing installs!

Your help would be alot appreciated!
[XDA-University] shoey63:
Please don't use updater scripts from other devices. Boot partition from one can be a bootloader partition for another. And you seriously don't want to flash a boot.img onto your bootloader partition (=hardbrick:eek:)
[XDA-University] Hnk1:
I have made my own updater script, what I am missing in here ?

I plan to flash sort of deodex rom for now after which i plan to make changes myself but I am stuck at updater script!

Cheers
[XDA-University] demkantor:
So this is a ROM you ported from one device to another then?

First thing you need to do when changing the updater-script is find out your partition table compared to the other one. Then you need to change the mounting points in this updater-script to match yours or like said above you could end up with a hard brick.

Then you want to be sure to use the update-binary from your device not from the one you ported to and put this in your MET-INF folder.

Doing these two quick steps will allow it to flash to your phone but won't guarantee that it will work, this will depend on the changes you made to the ROM to make it work, but so long as you were close even if you get into a bootloop you should be able to pull a logcat to find the issue at that point.

For now look back to the beginning of this thread and I list a few ways to get your mount points, edit these changes in, swap update-binary files, then if you are still having issues post a copy of your new+old updater-scripts here

Best of luck!
[XDA-University] Hnk1:
Basically I am NOT porting the rom. I am just making a flashable stock rom which has been deodexed/edify/zipaligned/signed.

The only problem is that I am unable to make a proper updater script.

The meta-inf has been pulled from another deodexed rom which is prerooted/changed in framworks etc so formatting commands work fine but other does not and I end up with bootloop.

I read your scripts and few others and I will post my old vs new plus logcat soon
[XDA-University] demkantor:
OK, so both ROMs are specific for your device then? If that is the case then you probably won't have to edit anything in META-INF to make it flash.

I would be sure to pull recovery log and grab a logcat after the flash and try to see what is going on, if in a bootloop you often can get a logcat but if not try to grab a kernel log/last_kmsg
[XDA-University] Sagar_Patel:
Awesome!!!!

im newbie and I want to build CWM for my Micromax A46 because it stuck with bootloop and i cant even enable usb debug on....all i want is to flash its stock rom through cwm but i dont have update-binary...how can i get it?

Thanks for giving your valuable time...
[XDA-University] eragon5779:
I am trying to do something similar with my proscan plt7810k and need to somehow get the binary too. If you figure it out, please share!
[XDA-University] demkantor:
If all you are missing is the update-binary take it from any ROM for your device, if there isn't one try a universal gapps one maybe... But can't guarantee it will work. Will probably need to use busybox commands to mount and flash to partitions
[XDA-University] demkantor:
Hi,

Do you have an update-binary for your device? As in from an ota or stock ROM or whatever? Also note that there were significant changes in the update-binary between 4.3 and 4.4 so be sure to have a compatible one or change the update-binary accordingly