This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

what's mean of the issue

Hi,

i follow this link http://omappedia.org/wiki/4AI.1.4_OMAP4_Icecream_Sandwich_Panda_Notes#Build_Instructions

in part of Patching MYDROIDi typed

git am devicepanda1.patch

but got the issue below

previous rebase directory /home/administrator/Documents/4AI.1.4/mydroid/device/ti/panda/.git/rebase-apply still exists but mbox given.

i have downloaded the file devicepanda1.patch in 4AI.1.4/mydroid/device/ti/panda

how to solve it.

BR

Younger
  • This implies that you are were in the middle of a rebase when attempting to apply the patch. To resolve that you should try ...

    # git rebase --continue

    Or

    # git rebase --abort

    Cheers
    Jon

  • Hi,

    That means that your current commit is not the same that the parent of the patch you are trying to apply, probably you made some changes. To fix that you have to rebase the patch or move to the parent commit.

  • Israel Cepeda said:

    That means that your current commit is not the same that the parent of the patch you are trying to apply, probably you made some changes. To fix that you have to rebase the patch or move to the parent commit.

    Git should still attempt to apply the patch even if that was the cause. If it is unable to apply the patch it would tell you it was unable to do so. This error looks different to me.

    Jon

  • When using "git am" it also check for the commit id and you can get that kind of errors, if instead you use "git apply" it will just apply the patch without any verification to the repo, just the differences.

    It might apply the patch anyway but you will get that warning each time you apply a patch using "git am"

  • Israel Cepeda said:

    When using "git am" it also check for the commit id and you can get that kind of errors, if instead you use "git apply" it will just apply the patch without any verification to the repo, just the differences.

    I use git am all the time to apply patches I have saved from mailing lists to mbox files. As I mentioned it is fails to apply the patch it will tell you. You will not get the error that was mentioned above.

    Jon

  • Israel Cepeda said:

    When using "git am" it also check for the commit id and you can get that kind of errors, if instead you use "git apply" it will just apply the patch without any verification to the repo, just the differences.

    It might apply the patch anyway but you will get that warning each time you apply a patch using "git am"

    You should note that if the patch will not apply due to changes made in the code then it will not apply with either "git am" or "git apply". From that stand point there is no difference.

    Now if you were doing some rebasing or had applied some other patch with "git am" that failed, git would not allow you to apply another patch with "git am" until you completed what you were doing (which is what you want). However, you could apply changes with "git apply" because it does not check if you are in the midst of a rebase, etc. However, I would not recommend that as "git apply" does not commit the change and hence keep the authorship, changelog, etc.

    The wiki says to use git am and that is the correct way to apply these patches. Git apply should not be used in this case as that is not a good way to maintain patches.

    Jon

  • Hi, Jon

    i have tyied both of  your idea, but got this issue below

    It looks like git-am is in progress. Cannot rebase.

    could u help me?

    BR

    Younger

  • Younger Su said:

    i have tyied both of  your idea, but got this issue below

    It looks like git-am is in progress. Cannot rebase.

    could u help me?

    If there is a previous "git am" in progress, then you should execute "git am --abort" and try again. If "git am" fails to apply a patch and you need to manually merge the changes. I recommend the following procedure ...

    1. Apply the patch

    # git am -3 <patch-name>

    2. If "git am" fails, then

    # git apply --reject <patch-name>

    This will appy what is can, and what it cannot apply will be place in a file called *.c.rej. Then you need to manually merge the changes in the *.c.rej.

    3. Once the changes have been merged execute ...

    # git add <filenames-modified>
    # git am --resolved

    Cheers
    Jon