[ONE Android Development] smint86:
So, I wanted to learn a little bit more and produce a f2f2-mixed flashable version out of Temasek v5.4 linaro. Unfortunately, it already failed at the first step:

The script is intended to create a "ramdisk" and a "split_img" folder and fill it with the files extracted from boot img. As the .zip already contained a ramdisk folder, I removed it in prior of using the

bash unpackimg.sh boot.img

command. The output is the following:

chris@christian-LIFEBOOK-C1410:~/ramdisk_one_plus_one-master$ bash unpackimg.sh boot.img
[3;J
\nAndroid Image Kitchen - UnpackImg Script
by osm0sis @ xda-developers\n
Supplied image: boot.img\n
Setting up work folders...\n
Splitting image to "split_img/"...\n
BOARD_KERNEL_CMDLINE console=ttyHSL0,115200,n8 androidboot.hardware=bacon user_debug=31 msm_rtb.filter=0x3F ehci-hcd.park=3 androidboot.selinux=permissive
BOARD_KERNEL_BASE 00000000
BOARD_PAGE_SIZE 2048
BOARD_KERNEL_OFFSET 00008000
BOARD_RAMDISK_OFFSET 02000000
BOARD_TAGS_OFFSET 01e00000
BOARD_DT_SIZE 231424
/home/chris/ramdisk_one_plus_one-master/bin/magic, 274: Warning: Printf format `l' is not valid for type `long' in description `, original size: %ld bytes'
/home/chris/ramdisk_one_plus_one-master/bin/magic, 879: Warning: Printf format `l' is not valid for type `beshort' in description `- version %ld'
file: could not find any valid magic files!
\nUnpacking ramdisk to "ramdisk/"...\n
Compression used:
Error!
unpackimg.sh: Zeile 74: return: »Return« ist nur aus einer Funktion oder einem mit »source« ausgefühten Skript möglich.
unpackimg.sh: Zeile 76: -dc: Kommando nicht gefunden.
cpio: verfrühtes Ende des Archivs
Error!
unpackimg.sh: Zeile 79: return: »Return« ist nur aus einer Funktion oder einem mit »source« ausgefühten Skript möglich.
\nDone!
unpackimg.sh: Zeile 84: return: »Return« ist nur aus einer Funktion oder einem mit »source« ausgefühten Skript möglich.
chris@christian-LIFEBOOK-C1410:~/ramdisk_one_plus_one-master$

Both ("ramdisk" and "split_img") folders are created, but ramdisk folder stays empty so I got no fstab.bacon file to edit. Help highly appreciated :).

edit: Using Lubuntu 14.10, but I think that should make no difference.

edit2: Thought it could be because of deleting ramdisk folder in advance, so I made the steps again, leaving everything as it comes out of master.zip. Gives me:

chris@christian-LIFEBOOK-C1410:~/Downloads/boot-tools$ bash unpackimg.sh boot.img
[3;J
\nAndroid Image Kitchen - UnpackImg Script
by osm0sis @ xda-developers\n
Supplied image: boot.img\n
Setting up work folders...\n
mkdir: das Verzeichnis »ramdisk“ kann nicht angelegt werden: Die Datei existiert bereits
Splitting image to "split_img/"...\n
BOARD_KERNEL_CMDLINE console=ttyHSL0,115200,n8 androidboot.hardware=bacon user_debug=31 msm_rtb.filter=0x3F ehci-hcd.park=3 androidboot.selinux=permissive
BOARD_KERNEL_BASE 00000000
BOARD_PAGE_SIZE 2048
BOARD_KERNEL_OFFSET 00008000
BOARD_RAMDISK_OFFSET 02000000
BOARD_TAGS_OFFSET 01e00000
BOARD_DT_SIZE 231424
/home/chris/Downloads/boot-tools/bin/magic, 274: Warning: Printf format `l' is not valid for type `long' in description `, original size: %ld bytes'
/home/chris/Downloads/boot-tools/bin/magic, 879: Warning: Printf format `l' is not valid for type `beshort' in description `- version %ld'
file: could not find any valid magic files!
\nUnpacking ramdisk to "ramdisk/"...\n
Compression used:
Error!
unpackimg.sh: Zeile 74: return: »Return« ist nur aus einer Funktion oder einem mit »source« ausgefühten Skript möglich.
unpackimg.sh: Zeile 76: -dc: Kommando nicht gefunden.
cpio: verfrühtes Ende des Archivs
Error!
unpackimg.sh: Zeile 79: return: »Return« ist nur aus einer Funktion oder einem mit »source« ausgefühten Skript möglich.
\nDone!
unpackimg.sh: Zeile 84: return: »Return« ist nur aus einer Funktion oder einem mit »source« ausgefühten Skript möglich.
chris@christian-LIFEBOOK-C1410:~/Downloads/boot-tools$

This time, ramdisk folder is not empty but contains also a fstab.bacon file, but only because this already is in master.zip (which comes with a ramdisk folder containing fstab.bacon). The files aren't changed at all, I think this is not as it's intented to be. It shows the same errors... Waiting for replys from more experienced users/devs :).

edit3: I got it, using other tools from another source to unpack boot.img and edit ramdisk files. I got them from here http://xdaforums.com/showthread.php?t=2073775 (AIK-Linux-v1.7-ALL.tar.gz)

./unpackimg.sh boot.img

worked like a charm. Also has a cleanup.sh file to run afterwards. Maybe you should update your description with this one.