--
You received this message because you are subscribed to the "Android Building" mailing list.
To post to this group, send email to android-...@googlegroups.com
To unsubscribe from this group, send email to
android-buildi...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en
> I tried simg2img and the command prints 'bad magic' when I use it on
> userdata.img. To get an ext4 image I used "adb pull /data dest/" then
> the make_ext4 command.
>
> The Makefile in build/core/ seems intersting. There are tests which
> choose if the images will be yaffs2 or ext2/3/4. What I don't
> understant is why it is not used? I added "echo .. >> /tmp/result"
> commands before some tests to get the default value of parameters but
> the output file is never created.
How did you add those commands? The makefile is not a shell script where
you can add generic commands wherever you like. If you want to obtain
the value of a variable at a certain point I often use the $(error ...)
macro to halt execution with a message:
$(error Interesting variable: "$(TARGET_BOOTIMAGE_USE_EXT2)")
Not sure if the double quotes will survive to the actual message, but
it's a good idea to surround the variable reference by some character
that will be printed -- otherwise it'll be hard to distinguish between
a variable that's really empty and one that contains one or more spaces.
As strings are often checked for emptiness that distinction can be
vital.
If $(TARGET_BOOTIMAGE_USE_EXT2) isn't set anywhere in your source code
it'll be empty, meaning you'll get yaffs images.
--
Magnus B�ck Opinions are my own and do not necessarily
SW Configuration Manager represent the ones of my employer, etc.
Sony Ericsson
> On 13 mai, 16:37, Magnus B�ck <magnus.b...@sonyericsson.com> wrote:
>
> > How did you add those commands? The makefile is not a shell script
> > where you can add generic commands wherever you like. If you want to
> > obtain the value of a variable at a certain point I often use the
> > $(error ...) macro to halt execution with a message:
> >
> > � �$(error Interesting variable: "$(TARGET_BOOTIMAGE_USE_EXT2)")
[...]
> > If $(TARGET_BOOTIMAGE_USE_EXT2) isn't set anywhere in your source
> > code it'll be empty, meaning you'll get yaffs images.
>
> Here is what my commands look like
>
> @echo "TARGET_BOOTIMAGE_USE_EXT2 : ($(TARGET_BOOTIMAGE_USE_EXT2))" > /
> tmp/android/output.txt
And you put that one a line by itself, not indented with
a tab character and part of a rule? That will never ever
work. See what I wrote about using the $(error ...) macro
for printf-style debugging of makefiles.